public static final class TextClassificationConfig.Builder extends GeneratedMessageV3.Builder<TextClassificationConfig.Builder> implements TextClassificationConfigOrBuilder
Config for text classification human labeling task.
Protobuf type google.cloud.datalabeling.v1beta1.TextClassificationConfig
Inherited Members
com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int)
com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int)
com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder)
Static Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public TextClassificationConfig.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
build()
public TextClassificationConfig build()
Returns
buildPartial()
public TextClassificationConfig buildPartial()
Returns
clear()
public TextClassificationConfig.Builder clear()
Returns
Overrides
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
clearAnnotationSpecSet()
public TextClassificationConfig.Builder clearAnnotationSpecSet()
Required. Annotation spec set resource name.
string annotation_spec_set = 2 [(.google.api.field_behavior) = REQUIRED];
Returns
clearField(Descriptors.FieldDescriptor field)
public TextClassificationConfig.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Returns
Overrides
clearOneof(Descriptors.OneofDescriptor oneof)
public TextClassificationConfig.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Returns
Overrides
clearSentimentConfig()
public TextClassificationConfig.Builder clearSentimentConfig()
Optional. Configs for sentiment selection.
.google.cloud.datalabeling.v1beta1.SentimentConfig sentiment_config = 3 [(.google.api.field_behavior) = OPTIONAL];
Returns
clone()
public TextClassificationConfig.Builder clone()
Returns
Overrides
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];
Returns
Type | Description |
boolean | The allowMultiLabel.
|
getAnnotationSpecSet()
public String getAnnotationSpecSet()
Required. Annotation spec set resource name.
string annotation_spec_set = 2 [(.google.api.field_behavior) = REQUIRED];
Returns
Type | Description |
String | The annotationSpecSet.
|
getAnnotationSpecSetBytes()
public ByteString getAnnotationSpecSetBytes()
Required. Annotation spec set resource name.
string annotation_spec_set = 2 [(.google.api.field_behavior) = REQUIRED];
Returns
Type | Description |
ByteString | The bytes for annotationSpecSet.
|
getDefaultInstanceForType()
public TextClassificationConfig getDefaultInstanceForType()
Returns
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Returns
Overrides
getSentimentConfig()
public SentimentConfig getSentimentConfig()
Optional. Configs for sentiment selection.
.google.cloud.datalabeling.v1beta1.SentimentConfig sentiment_config = 3 [(.google.api.field_behavior) = OPTIONAL];
Returns
getSentimentConfigBuilder()
public SentimentConfig.Builder getSentimentConfigBuilder()
Optional. Configs for sentiment selection.
.google.cloud.datalabeling.v1beta1.SentimentConfig sentiment_config = 3 [(.google.api.field_behavior) = OPTIONAL];
Returns
getSentimentConfigOrBuilder()
public SentimentConfigOrBuilder getSentimentConfigOrBuilder()
Optional. Configs for sentiment selection.
.google.cloud.datalabeling.v1beta1.SentimentConfig sentiment_config = 3 [(.google.api.field_behavior) = OPTIONAL];
Returns
hasSentimentConfig()
public boolean hasSentimentConfig()
Optional. Configs for sentiment selection.
.google.cloud.datalabeling.v1beta1.SentimentConfig sentiment_config = 3 [(.google.api.field_behavior) = OPTIONAL];
Returns
Type | Description |
boolean | Whether the sentimentConfig field is set.
|
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
mergeFrom(TextClassificationConfig other)
public TextClassificationConfig.Builder mergeFrom(TextClassificationConfig other)
Parameter
Returns
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public TextClassificationConfig.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Overrides
Exceptions
mergeFrom(Message other)
public TextClassificationConfig.Builder mergeFrom(Message other)
Parameter
Returns
Overrides
mergeSentimentConfig(SentimentConfig value)
public TextClassificationConfig.Builder mergeSentimentConfig(SentimentConfig value)
Optional. Configs for sentiment selection.
.google.cloud.datalabeling.v1beta1.SentimentConfig sentiment_config = 3 [(.google.api.field_behavior) = OPTIONAL];
Parameter
Returns
mergeUnknownFields(UnknownFieldSet unknownFields)
public final TextClassificationConfig.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides
setAllowMultiLabel(boolean value)
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];
Parameter
Name | Description |
value | boolean
The allowMultiLabel to set.
|
Returns
setAnnotationSpecSet(String value)
public TextClassificationConfig.Builder setAnnotationSpecSet(String value)
Required. Annotation spec set resource name.
string annotation_spec_set = 2 [(.google.api.field_behavior) = REQUIRED];
Parameter
Name | Description |
value | String
The annotationSpecSet to set.
|
Returns
setAnnotationSpecSetBytes(ByteString value)
public TextClassificationConfig.Builder setAnnotationSpecSetBytes(ByteString value)
Required. Annotation spec set resource name.
string annotation_spec_set = 2 [(.google.api.field_behavior) = REQUIRED];
Parameter
Name | Description |
value | ByteString
The bytes for annotationSpecSet to set.
|
Returns
setField(Descriptors.FieldDescriptor field, Object value)
public TextClassificationConfig.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public TextClassificationConfig.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Returns
Overrides
setSentimentConfig(SentimentConfig value)
public TextClassificationConfig.Builder setSentimentConfig(SentimentConfig value)
Optional. Configs for sentiment selection.
.google.cloud.datalabeling.v1beta1.SentimentConfig sentiment_config = 3 [(.google.api.field_behavior) = OPTIONAL];
Parameter
Returns
setSentimentConfig(SentimentConfig.Builder builderForValue)
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];
Parameter
Returns
setUnknownFields(UnknownFieldSet unknownFields)
public final TextClassificationConfig.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides