Class TextClassificationConfig.Builder

    • 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<TextClassificationConfig.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<TextClassificationConfig.Builder>
      • getDefaultInstanceForType

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

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

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

        public TextClassificationConfig.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<TextClassificationConfig.Builder>
      • addRepeatedField

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

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

        public TextClassificationConfig.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<TextClassificationConfig.Builder>
        Throws:
        IOException
      • getAllowMultiLabel

        public boolean getAllowMultiLabel()
         Optional. If allow_multi_label is true, contributors are able to choose
         multiple labels for one text segment.
         
        bool allow_multi_label = 1 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getAllowMultiLabel in interface TextClassificationConfigOrBuilder
        Returns:
        The allowMultiLabel.
      • setAllowMultiLabel

        public TextClassificationConfig.Builder setAllowMultiLabel​(boolean value)
         Optional. If allow_multi_label is true, contributors are able to choose
         multiple labels for one text segment.
         
        bool allow_multi_label = 1 [(.google.api.field_behavior) = OPTIONAL];
        Parameters:
        value - The allowMultiLabel to set.
        Returns:
        This builder for chaining.
      • clearAllowMultiLabel

        public TextClassificationConfig.Builder clearAllowMultiLabel()
         Optional. If allow_multi_label is true, contributors are able to choose
         multiple labels for one text segment.
         
        bool allow_multi_label = 1 [(.google.api.field_behavior) = OPTIONAL];
        Returns:
        This builder for chaining.
      • getAnnotationSpecSet

        public String getAnnotationSpecSet()
         Required. Annotation spec set resource name.
         
        string annotation_spec_set = 2 [(.google.api.field_behavior) = REQUIRED];
        Specified by:
        getAnnotationSpecSet in interface TextClassificationConfigOrBuilder
        Returns:
        The annotationSpecSet.
      • getAnnotationSpecSetBytes

        public com.google.protobuf.ByteString getAnnotationSpecSetBytes()
         Required. Annotation spec set resource name.
         
        string annotation_spec_set = 2 [(.google.api.field_behavior) = REQUIRED];
        Specified by:
        getAnnotationSpecSetBytes in interface TextClassificationConfigOrBuilder
        Returns:
        The bytes for annotationSpecSet.
      • setAnnotationSpecSet

        public TextClassificationConfig.Builder setAnnotationSpecSet​(String value)
         Required. Annotation spec set resource name.
         
        string annotation_spec_set = 2 [(.google.api.field_behavior) = REQUIRED];
        Parameters:
        value - The annotationSpecSet to set.
        Returns:
        This builder for chaining.
      • clearAnnotationSpecSet

        public TextClassificationConfig.Builder clearAnnotationSpecSet()
         Required. Annotation spec set resource name.
         
        string annotation_spec_set = 2 [(.google.api.field_behavior) = REQUIRED];
        Returns:
        This builder for chaining.
      • setAnnotationSpecSetBytes

        public TextClassificationConfig.Builder setAnnotationSpecSetBytes​(com.google.protobuf.ByteString value)
         Required. Annotation spec set resource name.
         
        string annotation_spec_set = 2 [(.google.api.field_behavior) = REQUIRED];
        Parameters:
        value - The bytes for annotationSpecSet to set.
        Returns:
        This builder for chaining.
      • hasSentimentConfig

        public boolean hasSentimentConfig()
         Optional. Configs for sentiment selection.
         
        .google.cloud.datalabeling.v1beta1.SentimentConfig sentiment_config = 3 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        hasSentimentConfig in interface TextClassificationConfigOrBuilder
        Returns:
        Whether the sentimentConfig field is set.
      • getSentimentConfig

        public SentimentConfig getSentimentConfig()
         Optional. Configs for sentiment selection.
         
        .google.cloud.datalabeling.v1beta1.SentimentConfig sentiment_config = 3 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getSentimentConfig in interface TextClassificationConfigOrBuilder
        Returns:
        The sentimentConfig.
      • setSentimentConfig

        public TextClassificationConfig.Builder setSentimentConfig​(SentimentConfig value)
         Optional. Configs for sentiment selection.
         
        .google.cloud.datalabeling.v1beta1.SentimentConfig sentiment_config = 3 [(.google.api.field_behavior) = OPTIONAL];
      • setSentimentConfig

        public TextClassificationConfig.Builder setSentimentConfig​(SentimentConfig.Builder builderForValue)
         Optional. Configs for sentiment selection.
         
        .google.cloud.datalabeling.v1beta1.SentimentConfig sentiment_config = 3 [(.google.api.field_behavior) = OPTIONAL];
      • mergeSentimentConfig

        public TextClassificationConfig.Builder mergeSentimentConfig​(SentimentConfig value)
         Optional. Configs for sentiment selection.
         
        .google.cloud.datalabeling.v1beta1.SentimentConfig sentiment_config = 3 [(.google.api.field_behavior) = OPTIONAL];
      • clearSentimentConfig

        public TextClassificationConfig.Builder clearSentimentConfig()
         Optional. Configs for sentiment selection.
         
        .google.cloud.datalabeling.v1beta1.SentimentConfig sentiment_config = 3 [(.google.api.field_behavior) = OPTIONAL];
      • getSentimentConfigBuilder

        public SentimentConfig.Builder getSentimentConfigBuilder()
         Optional. Configs for sentiment selection.
         
        .google.cloud.datalabeling.v1beta1.SentimentConfig sentiment_config = 3 [(.google.api.field_behavior) = OPTIONAL];
      • setUnknownFields

        public final TextClassificationConfig.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<TextClassificationConfig.Builder>
      • mergeUnknownFields

        public final TextClassificationConfig.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<TextClassificationConfig.Builder>