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.automl.v1.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
 A definition of an annotation spec.
 
Protobuf type google.cloud.automl.v1.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
    • getName

      public String getName()
       Output only. Resource name of the annotation spec.
       Form:
       'projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/annotationSpecs/{annotation_spec_id}'
       
      string name = 1;
      Specified by:
      getName in interface AnnotationSpecOrBuilder
      Returns:
      The name.
    • getNameBytes

      public com.google.protobuf.ByteString getNameBytes()
       Output only. Resource name of the annotation spec.
       Form:
       'projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/annotationSpecs/{annotation_spec_id}'
       
      string name = 1;
      Specified by:
      getNameBytes in interface AnnotationSpecOrBuilder
      Returns:
      The bytes for name.
    • setName

      public AnnotationSpec.Builder setName(String value)
       Output only. Resource name of the annotation spec.
       Form:
       'projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/annotationSpecs/{annotation_spec_id}'
       
      string name = 1;
      Parameters:
      value - The name to set.
      Returns:
      This builder for chaining.
    • clearName

      public AnnotationSpec.Builder clearName()
       Output only. Resource name of the annotation spec.
       Form:
       'projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/annotationSpecs/{annotation_spec_id}'
       
      string name = 1;
      Returns:
      This builder for chaining.
    • setNameBytes

      public AnnotationSpec.Builder setNameBytes(com.google.protobuf.ByteString value)
       Output only. Resource name of the annotation spec.
       Form:
       'projects/{project_id}/locations/{location_id}/datasets/{dataset_id}/annotationSpecs/{annotation_spec_id}'
       
      string name = 1;
      Parameters:
      value - The bytes for name to set.
      Returns:
      This builder for chaining.
    • getDisplayName

      public String getDisplayName()
       Required. The name of the annotation spec to show in the interface. The name can be
       up to 32 characters long and must match the regexp `[a-zA-Z0-9_]+`.
       
      string display_name = 2;
      Specified by:
      getDisplayName in interface AnnotationSpecOrBuilder
      Returns:
      The displayName.
    • getDisplayNameBytes

      public com.google.protobuf.ByteString getDisplayNameBytes()
       Required. The name of the annotation spec to show in the interface. The name can be
       up to 32 characters long and must match the regexp `[a-zA-Z0-9_]+`.
       
      string display_name = 2;
      Specified by:
      getDisplayNameBytes in interface AnnotationSpecOrBuilder
      Returns:
      The bytes for displayName.
    • setDisplayName

      public AnnotationSpec.Builder setDisplayName(String value)
       Required. The name of the annotation spec to show in the interface. The name can be
       up to 32 characters long and must match the regexp `[a-zA-Z0-9_]+`.
       
      string display_name = 2;
      Parameters:
      value - The displayName to set.
      Returns:
      This builder for chaining.
    • clearDisplayName

      public AnnotationSpec.Builder clearDisplayName()
       Required. The name of the annotation spec to show in the interface. The name can be
       up to 32 characters long and must match the regexp `[a-zA-Z0-9_]+`.
       
      string display_name = 2;
      Returns:
      This builder for chaining.
    • setDisplayNameBytes

      public AnnotationSpec.Builder setDisplayNameBytes(com.google.protobuf.ByteString value)
       Required. The name of the annotation spec to show in the interface. The name can be
       up to 32 characters long and must match the regexp `[a-zA-Z0-9_]+`.
       
      string display_name = 2;
      Parameters:
      value - The bytes for displayName to set.
      Returns:
      This builder for chaining.
    • getExampleCount

      public int getExampleCount()
       Output only. The number of examples in the parent dataset
       labeled by the annotation spec.
       
      int32 example_count = 9;
      Specified by:
      getExampleCount in interface AnnotationSpecOrBuilder
      Returns:
      The exampleCount.
    • setExampleCount

      public AnnotationSpec.Builder setExampleCount(int value)
       Output only. The number of examples in the parent dataset
       labeled by the annotation spec.
       
      int32 example_count = 9;
      Parameters:
      value - The exampleCount to set.
      Returns:
      This builder for chaining.
    • clearExampleCount

      public AnnotationSpec.Builder clearExampleCount()
       Output only. The number of examples in the parent dataset
       labeled by the annotation spec.
       
      int32 example_count = 9;
      Returns:
      This builder for chaining.