Class AnnotationSpec.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<AnnotationSpec.Builder>
com.google.cloud.datalabeling.v1beta1.AnnotationSpec.Builder
All Implemented Interfaces:
AnnotationSpecOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
AnnotationSpec

public static final class AnnotationSpec.Builder extends com.google.protobuf.GeneratedMessage.Builder<AnnotationSpec.Builder> implements AnnotationSpecOrBuilder
 Container of information related to one possible annotation that can be used
 in a labeling task. For example, an image classification task where images
 are labeled as `dog` or `cat` must reference an AnnotationSpec for `dog` and
 an AnnotationSpec for `cat`.
 
Protobuf type google.cloud.datalabeling.v1beta1.AnnotationSpec
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<AnnotationSpec.Builder>
    • clear

      public AnnotationSpec.Builder clear()
      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessage.Builder<AnnotationSpec.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessage.Builder<AnnotationSpec.Builder>
    • getDefaultInstanceForType

      public AnnotationSpec getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public AnnotationSpec build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public AnnotationSpec buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public AnnotationSpec.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<AnnotationSpec.Builder>
    • mergeFrom

      public AnnotationSpec.Builder mergeFrom(AnnotationSpec other)
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage.Builder<AnnotationSpec.Builder>
    • mergeFrom

      public AnnotationSpec.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<AnnotationSpec.Builder>
      Throws:
      IOException
    • getDisplayName

      public String getDisplayName()
       Required. The display name of the AnnotationSpec. Maximum of 64 characters.
       
      string display_name = 1;
      Specified by:
      getDisplayName in interface AnnotationSpecOrBuilder
      Returns:
      The displayName.
    • getDisplayNameBytes

      public com.google.protobuf.ByteString getDisplayNameBytes()
       Required. The display name of the AnnotationSpec. Maximum of 64 characters.
       
      string display_name = 1;
      Specified by:
      getDisplayNameBytes in interface AnnotationSpecOrBuilder
      Returns:
      The bytes for displayName.
    • setDisplayName

      public AnnotationSpec.Builder setDisplayName(String value)
       Required. The display name of the AnnotationSpec. Maximum of 64 characters.
       
      string display_name = 1;
      Parameters:
      value - The displayName to set.
      Returns:
      This builder for chaining.
    • clearDisplayName

      public AnnotationSpec.Builder clearDisplayName()
       Required. The display name of the AnnotationSpec. Maximum of 64 characters.
       
      string display_name = 1;
      Returns:
      This builder for chaining.
    • setDisplayNameBytes

      public AnnotationSpec.Builder setDisplayNameBytes(com.google.protobuf.ByteString value)
       Required. The display name of the AnnotationSpec. Maximum of 64 characters.
       
      string display_name = 1;
      Parameters:
      value - The bytes for displayName to set.
      Returns:
      This builder for chaining.
    • getDescription

      public String getDescription()
       Optional. User-provided description of the annotation specification.
       The description can be up to 10,000 characters long.
       
      string description = 2;
      Specified by:
      getDescription in interface AnnotationSpecOrBuilder
      Returns:
      The description.
    • getDescriptionBytes

      public com.google.protobuf.ByteString getDescriptionBytes()
       Optional. User-provided description of the annotation specification.
       The description can be up to 10,000 characters long.
       
      string description = 2;
      Specified by:
      getDescriptionBytes in interface AnnotationSpecOrBuilder
      Returns:
      The bytes for description.
    • setDescription

      public AnnotationSpec.Builder setDescription(String value)
       Optional. User-provided description of the annotation specification.
       The description can be up to 10,000 characters long.
       
      string description = 2;
      Parameters:
      value - The description to set.
      Returns:
      This builder for chaining.
    • clearDescription

      public AnnotationSpec.Builder clearDescription()
       Optional. User-provided description of the annotation specification.
       The description can be up to 10,000 characters long.
       
      string description = 2;
      Returns:
      This builder for chaining.
    • setDescriptionBytes

      public AnnotationSpec.Builder setDescriptionBytes(com.google.protobuf.ByteString value)
       Optional. User-provided description of the annotation specification.
       The description can be up to 10,000 characters long.
       
      string description = 2;
      Parameters:
      value - The bytes for description to set.
      Returns:
      This builder for chaining.