Class AnnotationPayload.Builder

  • All Implemented Interfaces:
    AnnotationPayloadOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
    Enclosing class:
    AnnotationPayload

    public static final class AnnotationPayload.Builder
    extends com.google.protobuf.GeneratedMessageV3.Builder<AnnotationPayload.Builder>
    implements AnnotationPayloadOrBuilder
     Contains annotation information that is relevant to AutoML.
     
    Protobuf type google.cloud.automl.v1beta1.AnnotationPayload
    • Method Detail

      • getDescriptor

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

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

        public AnnotationPayload.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.GeneratedMessageV3.Builder<AnnotationPayload.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.GeneratedMessageV3.Builder<AnnotationPayload.Builder>
      • getDefaultInstanceForType

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

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

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

        public AnnotationPayload.Builder clone()
        Specified by:
        clone in interface com.google.protobuf.Message.Builder
        Specified by:
        clone in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        clone in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotationPayload.Builder>
      • setField

        public AnnotationPayload.Builder setField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                  Object value)
        Specified by:
        setField in interface com.google.protobuf.Message.Builder
        Overrides:
        setField in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotationPayload.Builder>
      • clearField

        public AnnotationPayload.Builder clearField​(com.google.protobuf.Descriptors.FieldDescriptor field)
        Specified by:
        clearField in interface com.google.protobuf.Message.Builder
        Overrides:
        clearField in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotationPayload.Builder>
      • clearOneof

        public AnnotationPayload.Builder clearOneof​(com.google.protobuf.Descriptors.OneofDescriptor oneof)
        Specified by:
        clearOneof in interface com.google.protobuf.Message.Builder
        Overrides:
        clearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotationPayload.Builder>
      • setRepeatedField

        public AnnotationPayload.Builder setRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                          int index,
                                                          Object value)
        Specified by:
        setRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        setRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotationPayload.Builder>
      • addRepeatedField

        public AnnotationPayload.Builder addRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                          Object value)
        Specified by:
        addRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotationPayload.Builder>
      • mergeFrom

        public AnnotationPayload.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<AnnotationPayload.Builder>
      • isInitialized

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

        public AnnotationPayload.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<AnnotationPayload.Builder>
        Throws:
        IOException
      • hasTranslation

        public boolean hasTranslation()
         Annotation details for translation.
         
        .google.cloud.automl.v1beta1.TranslationAnnotation translation = 2;
        Specified by:
        hasTranslation in interface AnnotationPayloadOrBuilder
        Returns:
        Whether the translation field is set.
      • clearTranslation

        public AnnotationPayload.Builder clearTranslation()
         Annotation details for translation.
         
        .google.cloud.automl.v1beta1.TranslationAnnotation translation = 2;
      • getTranslationBuilder

        public TranslationAnnotation.Builder getTranslationBuilder()
         Annotation details for translation.
         
        .google.cloud.automl.v1beta1.TranslationAnnotation translation = 2;
      • hasClassification

        public boolean hasClassification()
         Annotation details for content or image classification.
         
        .google.cloud.automl.v1beta1.ClassificationAnnotation classification = 3;
        Specified by:
        hasClassification in interface AnnotationPayloadOrBuilder
        Returns:
        Whether the classification field is set.
      • clearClassification

        public AnnotationPayload.Builder clearClassification()
         Annotation details for content or image classification.
         
        .google.cloud.automl.v1beta1.ClassificationAnnotation classification = 3;
      • hasImageObjectDetection

        public boolean hasImageObjectDetection()
         Annotation details for image object detection.
         
        .google.cloud.automl.v1beta1.ImageObjectDetectionAnnotation image_object_detection = 4;
        Specified by:
        hasImageObjectDetection in interface AnnotationPayloadOrBuilder
        Returns:
        Whether the imageObjectDetection field is set.
      • clearImageObjectDetection

        public AnnotationPayload.Builder clearImageObjectDetection()
         Annotation details for image object detection.
         
        .google.cloud.automl.v1beta1.ImageObjectDetectionAnnotation image_object_detection = 4;
      • getImageObjectDetectionBuilder

        public ImageObjectDetectionAnnotation.Builder getImageObjectDetectionBuilder()
         Annotation details for image object detection.
         
        .google.cloud.automl.v1beta1.ImageObjectDetectionAnnotation image_object_detection = 4;
      • hasVideoClassification

        public boolean hasVideoClassification()
         Annotation details for video classification.
         Returned for Video Classification predictions.
         
        .google.cloud.automl.v1beta1.VideoClassificationAnnotation video_classification = 9;
        Specified by:
        hasVideoClassification in interface AnnotationPayloadOrBuilder
        Returns:
        Whether the videoClassification field is set.
      • clearVideoClassification

        public AnnotationPayload.Builder clearVideoClassification()
         Annotation details for video classification.
         Returned for Video Classification predictions.
         
        .google.cloud.automl.v1beta1.VideoClassificationAnnotation video_classification = 9;
      • getVideoClassificationBuilder

        public ClassificationProto.VideoClassificationAnnotation.Builder getVideoClassificationBuilder()
         Annotation details for video classification.
         Returned for Video Classification predictions.
         
        .google.cloud.automl.v1beta1.VideoClassificationAnnotation video_classification = 9;
      • hasVideoObjectTracking

        public boolean hasVideoObjectTracking()
         Annotation details for video object tracking.
         
        .google.cloud.automl.v1beta1.VideoObjectTrackingAnnotation video_object_tracking = 8;
        Specified by:
        hasVideoObjectTracking in interface AnnotationPayloadOrBuilder
        Returns:
        Whether the videoObjectTracking field is set.
      • clearVideoObjectTracking

        public AnnotationPayload.Builder clearVideoObjectTracking()
         Annotation details for video object tracking.
         
        .google.cloud.automl.v1beta1.VideoObjectTrackingAnnotation video_object_tracking = 8;
      • getVideoObjectTrackingBuilder

        public VideoObjectTrackingAnnotation.Builder getVideoObjectTrackingBuilder()
         Annotation details for video object tracking.
         
        .google.cloud.automl.v1beta1.VideoObjectTrackingAnnotation video_object_tracking = 8;
      • hasTextExtraction

        public boolean hasTextExtraction()
         Annotation details for text extraction.
         
        .google.cloud.automl.v1beta1.TextExtractionAnnotation text_extraction = 6;
        Specified by:
        hasTextExtraction in interface AnnotationPayloadOrBuilder
        Returns:
        Whether the textExtraction field is set.
      • clearTextExtraction

        public AnnotationPayload.Builder clearTextExtraction()
         Annotation details for text extraction.
         
        .google.cloud.automl.v1beta1.TextExtractionAnnotation text_extraction = 6;
      • getTextExtractionBuilder

        public TextExtractionAnnotation.Builder getTextExtractionBuilder()
         Annotation details for text extraction.
         
        .google.cloud.automl.v1beta1.TextExtractionAnnotation text_extraction = 6;
      • hasTextSentiment

        public boolean hasTextSentiment()
         Annotation details for text sentiment.
         
        .google.cloud.automl.v1beta1.TextSentimentAnnotation text_sentiment = 7;
        Specified by:
        hasTextSentiment in interface AnnotationPayloadOrBuilder
        Returns:
        Whether the textSentiment field is set.
      • clearTextSentiment

        public AnnotationPayload.Builder clearTextSentiment()
         Annotation details for text sentiment.
         
        .google.cloud.automl.v1beta1.TextSentimentAnnotation text_sentiment = 7;
      • hasTables

        public boolean hasTables()
         Annotation details for Tables.
         
        .google.cloud.automl.v1beta1.TablesAnnotation tables = 10;
        Specified by:
        hasTables in interface AnnotationPayloadOrBuilder
        Returns:
        Whether the tables field is set.
      • clearTables

        public AnnotationPayload.Builder clearTables()
         Annotation details for Tables.
         
        .google.cloud.automl.v1beta1.TablesAnnotation tables = 10;
      • getTablesBuilder

        public TablesAnnotation.Builder getTablesBuilder()
         Annotation details for Tables.
         
        .google.cloud.automl.v1beta1.TablesAnnotation tables = 10;
      • getAnnotationSpecId

        public String getAnnotationSpecId()
         Output only . The resource ID of the annotation spec that
         this annotation pertains to. The annotation spec comes from either an
         ancestor dataset, or the dataset that was used to train the model in use.
         
        string annotation_spec_id = 1;
        Specified by:
        getAnnotationSpecId in interface AnnotationPayloadOrBuilder
        Returns:
        The annotationSpecId.
      • getAnnotationSpecIdBytes

        public com.google.protobuf.ByteString getAnnotationSpecIdBytes()
         Output only . The resource ID of the annotation spec that
         this annotation pertains to. The annotation spec comes from either an
         ancestor dataset, or the dataset that was used to train the model in use.
         
        string annotation_spec_id = 1;
        Specified by:
        getAnnotationSpecIdBytes in interface AnnotationPayloadOrBuilder
        Returns:
        The bytes for annotationSpecId.
      • setAnnotationSpecId

        public AnnotationPayload.Builder setAnnotationSpecId​(String value)
         Output only . The resource ID of the annotation spec that
         this annotation pertains to. The annotation spec comes from either an
         ancestor dataset, or the dataset that was used to train the model in use.
         
        string annotation_spec_id = 1;
        Parameters:
        value - The annotationSpecId to set.
        Returns:
        This builder for chaining.
      • clearAnnotationSpecId

        public AnnotationPayload.Builder clearAnnotationSpecId()
         Output only . The resource ID of the annotation spec that
         this annotation pertains to. The annotation spec comes from either an
         ancestor dataset, or the dataset that was used to train the model in use.
         
        string annotation_spec_id = 1;
        Returns:
        This builder for chaining.
      • setAnnotationSpecIdBytes

        public AnnotationPayload.Builder setAnnotationSpecIdBytes​(com.google.protobuf.ByteString value)
         Output only . The resource ID of the annotation spec that
         this annotation pertains to. The annotation spec comes from either an
         ancestor dataset, or the dataset that was used to train the model in use.
         
        string annotation_spec_id = 1;
        Parameters:
        value - The bytes for annotationSpecId to set.
        Returns:
        This builder for chaining.
      • getDisplayName

        public String getDisplayName()
         Output only. The value of
         [display_name][google.cloud.automl.v1beta1.AnnotationSpec.display_name]
         when the model was trained. Because this field returns a value at model
         training time, for different models trained using the same dataset, the
         returned value could be different as model owner could update the
         `display_name` between any two model training.
         
        string display_name = 5;
        Specified by:
        getDisplayName in interface AnnotationPayloadOrBuilder
        Returns:
        The displayName.
      • getDisplayNameBytes

        public com.google.protobuf.ByteString getDisplayNameBytes()
         Output only. The value of
         [display_name][google.cloud.automl.v1beta1.AnnotationSpec.display_name]
         when the model was trained. Because this field returns a value at model
         training time, for different models trained using the same dataset, the
         returned value could be different as model owner could update the
         `display_name` between any two model training.
         
        string display_name = 5;
        Specified by:
        getDisplayNameBytes in interface AnnotationPayloadOrBuilder
        Returns:
        The bytes for displayName.
      • setDisplayName

        public AnnotationPayload.Builder setDisplayName​(String value)
         Output only. The value of
         [display_name][google.cloud.automl.v1beta1.AnnotationSpec.display_name]
         when the model was trained. Because this field returns a value at model
         training time, for different models trained using the same dataset, the
         returned value could be different as model owner could update the
         `display_name` between any two model training.
         
        string display_name = 5;
        Parameters:
        value - The displayName to set.
        Returns:
        This builder for chaining.
      • clearDisplayName

        public AnnotationPayload.Builder clearDisplayName()
         Output only. The value of
         [display_name][google.cloud.automl.v1beta1.AnnotationSpec.display_name]
         when the model was trained. Because this field returns a value at model
         training time, for different models trained using the same dataset, the
         returned value could be different as model owner could update the
         `display_name` between any two model training.
         
        string display_name = 5;
        Returns:
        This builder for chaining.
      • setDisplayNameBytes

        public AnnotationPayload.Builder setDisplayNameBytes​(com.google.protobuf.ByteString value)
         Output only. The value of
         [display_name][google.cloud.automl.v1beta1.AnnotationSpec.display_name]
         when the model was trained. Because this field returns a value at model
         training time, for different models trained using the same dataset, the
         returned value could be different as model owner could update the
         `display_name` between any two model training.
         
        string display_name = 5;
        Parameters:
        value - The bytes for displayName to set.
        Returns:
        This builder for chaining.
      • setUnknownFields

        public final AnnotationPayload.Builder setUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        setUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        setUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotationPayload.Builder>
      • mergeUnknownFields

        public final AnnotationPayload.Builder mergeUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        mergeUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        mergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotationPayload.Builder>