Class Annotation.Builder
- java.lang.Object
-
- com.google.protobuf.AbstractMessageLite.Builder
-
- com.google.protobuf.AbstractMessage.Builder<BuilderT>
-
- com.google.protobuf.GeneratedMessageV3.Builder<Annotation.Builder>
-
- com.google.cloud.datalabeling.v1beta1.Annotation.Builder
-
- All Implemented Interfaces:
AnnotationOrBuilder,com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Cloneable
- Enclosing class:
- Annotation
public static final class Annotation.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Annotation.Builder> implements AnnotationOrBuilder
Annotation for Example. Each example may have one or more annotations. For example in image classification problem, each image might have one or more labels. We call labels binded with this image an Annotation.
Protobuf typegoogle.cloud.datalabeling.v1beta1.Annotation
-
-
Method Summary
-
Methods inherited from class com.google.protobuf.GeneratedMessageV3.Builder
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMutableMapField, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setUnknownFieldSetBuilder, setUnknownFieldsProto3
-
Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toString
-
Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageException
-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
-
-
-
Method Detail
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
-
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessageV3.Builder<Annotation.Builder>
-
clear
public Annotation.Builder clear()
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessageV3.Builder<Annotation.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.Message.Builder- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getDescriptorForTypein classcom.google.protobuf.GeneratedMessageV3.Builder<Annotation.Builder>
-
getDefaultInstanceForType
public Annotation getDefaultInstanceForType()
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
public Annotation build()
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
public Annotation buildPartial()
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
clone
public Annotation.Builder clone()
- Specified by:
clonein interfacecom.google.protobuf.Message.Builder- Specified by:
clonein interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clonein classcom.google.protobuf.GeneratedMessageV3.Builder<Annotation.Builder>
-
setField
public Annotation.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
- Specified by:
setFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
setFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<Annotation.Builder>
-
clearField
public Annotation.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
- Specified by:
clearFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
clearFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<Annotation.Builder>
-
clearOneof
public Annotation.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
- Specified by:
clearOneofin interfacecom.google.protobuf.Message.Builder- Overrides:
clearOneofin classcom.google.protobuf.GeneratedMessageV3.Builder<Annotation.Builder>
-
setRepeatedField
public Annotation.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
- Specified by:
setRepeatedFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
setRepeatedFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<Annotation.Builder>
-
addRepeatedField
public Annotation.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
- Specified by:
addRepeatedFieldin interfacecom.google.protobuf.Message.Builder- Overrides:
addRepeatedFieldin classcom.google.protobuf.GeneratedMessageV3.Builder<Annotation.Builder>
-
mergeFrom
public Annotation.Builder mergeFrom(com.google.protobuf.Message other)
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<Annotation.Builder>
-
mergeFrom
public Annotation.Builder mergeFrom(Annotation other)
-
isInitialized
public final boolean isInitialized()
- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessageV3.Builder<Annotation.Builder>
-
mergeFrom
public Annotation.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Specified by:
mergeFromin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<Annotation.Builder>- Throws:
IOException
-
getName
public String getName()
Output only. Unique name of this annotation, format is: projects/{project_id}/datasets/{dataset_id}/annotatedDatasets/{annotated_dataset}/examples/{example_id}/annotations/{annotation_id}string name = 1;- Specified by:
getNamein interfaceAnnotationOrBuilder- Returns:
- The name.
-
getNameBytes
public com.google.protobuf.ByteString getNameBytes()
Output only. Unique name of this annotation, format is: projects/{project_id}/datasets/{dataset_id}/annotatedDatasets/{annotated_dataset}/examples/{example_id}/annotations/{annotation_id}string name = 1;- Specified by:
getNameBytesin interfaceAnnotationOrBuilder- Returns:
- The bytes for name.
-
setName
public Annotation.Builder setName(String value)
Output only. Unique name of this annotation, format is: projects/{project_id}/datasets/{dataset_id}/annotatedDatasets/{annotated_dataset}/examples/{example_id}/annotations/{annotation_id}string name = 1;- Parameters:
value- The name to set.- Returns:
- This builder for chaining.
-
clearName
public Annotation.Builder clearName()
Output only. Unique name of this annotation, format is: projects/{project_id}/datasets/{dataset_id}/annotatedDatasets/{annotated_dataset}/examples/{example_id}/annotations/{annotation_id}string name = 1;- Returns:
- This builder for chaining.
-
setNameBytes
public Annotation.Builder setNameBytes(com.google.protobuf.ByteString value)
Output only. Unique name of this annotation, format is: projects/{project_id}/datasets/{dataset_id}/annotatedDatasets/{annotated_dataset}/examples/{example_id}/annotations/{annotation_id}string name = 1;- Parameters:
value- The bytes for name to set.- Returns:
- This builder for chaining.
-
getAnnotationSourceValue
public int getAnnotationSourceValue()
Output only. The source of the annotation.
.google.cloud.datalabeling.v1beta1.AnnotationSource annotation_source = 2;- Specified by:
getAnnotationSourceValuein interfaceAnnotationOrBuilder- Returns:
- The enum numeric value on the wire for annotationSource.
-
setAnnotationSourceValue
public Annotation.Builder setAnnotationSourceValue(int value)
Output only. The source of the annotation.
.google.cloud.datalabeling.v1beta1.AnnotationSource annotation_source = 2;- Parameters:
value- The enum numeric value on the wire for annotationSource to set.- Returns:
- This builder for chaining.
-
getAnnotationSource
public AnnotationSource getAnnotationSource()
Output only. The source of the annotation.
.google.cloud.datalabeling.v1beta1.AnnotationSource annotation_source = 2;- Specified by:
getAnnotationSourcein interfaceAnnotationOrBuilder- Returns:
- The annotationSource.
-
setAnnotationSource
public Annotation.Builder setAnnotationSource(AnnotationSource value)
Output only. The source of the annotation.
.google.cloud.datalabeling.v1beta1.AnnotationSource annotation_source = 2;- Parameters:
value- The annotationSource to set.- Returns:
- This builder for chaining.
-
clearAnnotationSource
public Annotation.Builder clearAnnotationSource()
Output only. The source of the annotation.
.google.cloud.datalabeling.v1beta1.AnnotationSource annotation_source = 2;- Returns:
- This builder for chaining.
-
hasAnnotationValue
public boolean hasAnnotationValue()
Output only. This is the actual annotation value, e.g classification, bounding box values are stored here.
.google.cloud.datalabeling.v1beta1.AnnotationValue annotation_value = 3;- Specified by:
hasAnnotationValuein interfaceAnnotationOrBuilder- Returns:
- Whether the annotationValue field is set.
-
getAnnotationValue
public AnnotationValue getAnnotationValue()
Output only. This is the actual annotation value, e.g classification, bounding box values are stored here.
.google.cloud.datalabeling.v1beta1.AnnotationValue annotation_value = 3;- Specified by:
getAnnotationValuein interfaceAnnotationOrBuilder- Returns:
- The annotationValue.
-
setAnnotationValue
public Annotation.Builder setAnnotationValue(AnnotationValue value)
Output only. This is the actual annotation value, e.g classification, bounding box values are stored here.
.google.cloud.datalabeling.v1beta1.AnnotationValue annotation_value = 3;
-
setAnnotationValue
public Annotation.Builder setAnnotationValue(AnnotationValue.Builder builderForValue)
Output only. This is the actual annotation value, e.g classification, bounding box values are stored here.
.google.cloud.datalabeling.v1beta1.AnnotationValue annotation_value = 3;
-
mergeAnnotationValue
public Annotation.Builder mergeAnnotationValue(AnnotationValue value)
Output only. This is the actual annotation value, e.g classification, bounding box values are stored here.
.google.cloud.datalabeling.v1beta1.AnnotationValue annotation_value = 3;
-
clearAnnotationValue
public Annotation.Builder clearAnnotationValue()
Output only. This is the actual annotation value, e.g classification, bounding box values are stored here.
.google.cloud.datalabeling.v1beta1.AnnotationValue annotation_value = 3;
-
getAnnotationValueBuilder
public AnnotationValue.Builder getAnnotationValueBuilder()
Output only. This is the actual annotation value, e.g classification, bounding box values are stored here.
.google.cloud.datalabeling.v1beta1.AnnotationValue annotation_value = 3;
-
getAnnotationValueOrBuilder
public AnnotationValueOrBuilder getAnnotationValueOrBuilder()
Output only. This is the actual annotation value, e.g classification, bounding box values are stored here.
.google.cloud.datalabeling.v1beta1.AnnotationValue annotation_value = 3;- Specified by:
getAnnotationValueOrBuilderin interfaceAnnotationOrBuilder
-
hasAnnotationMetadata
public boolean hasAnnotationMetadata()
Output only. Annotation metadata, including information like votes for labels.
.google.cloud.datalabeling.v1beta1.AnnotationMetadata annotation_metadata = 4;- Specified by:
hasAnnotationMetadatain interfaceAnnotationOrBuilder- Returns:
- Whether the annotationMetadata field is set.
-
getAnnotationMetadata
public AnnotationMetadata getAnnotationMetadata()
Output only. Annotation metadata, including information like votes for labels.
.google.cloud.datalabeling.v1beta1.AnnotationMetadata annotation_metadata = 4;- Specified by:
getAnnotationMetadatain interfaceAnnotationOrBuilder- Returns:
- The annotationMetadata.
-
setAnnotationMetadata
public Annotation.Builder setAnnotationMetadata(AnnotationMetadata value)
Output only. Annotation metadata, including information like votes for labels.
.google.cloud.datalabeling.v1beta1.AnnotationMetadata annotation_metadata = 4;
-
setAnnotationMetadata
public Annotation.Builder setAnnotationMetadata(AnnotationMetadata.Builder builderForValue)
Output only. Annotation metadata, including information like votes for labels.
.google.cloud.datalabeling.v1beta1.AnnotationMetadata annotation_metadata = 4;
-
mergeAnnotationMetadata
public Annotation.Builder mergeAnnotationMetadata(AnnotationMetadata value)
Output only. Annotation metadata, including information like votes for labels.
.google.cloud.datalabeling.v1beta1.AnnotationMetadata annotation_metadata = 4;
-
clearAnnotationMetadata
public Annotation.Builder clearAnnotationMetadata()
Output only. Annotation metadata, including information like votes for labels.
.google.cloud.datalabeling.v1beta1.AnnotationMetadata annotation_metadata = 4;
-
getAnnotationMetadataBuilder
public AnnotationMetadata.Builder getAnnotationMetadataBuilder()
Output only. Annotation metadata, including information like votes for labels.
.google.cloud.datalabeling.v1beta1.AnnotationMetadata annotation_metadata = 4;
-
getAnnotationMetadataOrBuilder
public AnnotationMetadataOrBuilder getAnnotationMetadataOrBuilder()
Output only. Annotation metadata, including information like votes for labels.
.google.cloud.datalabeling.v1beta1.AnnotationMetadata annotation_metadata = 4;- Specified by:
getAnnotationMetadataOrBuilderin interfaceAnnotationOrBuilder
-
getAnnotationSentimentValue
public int getAnnotationSentimentValue()
Output only. Sentiment for this annotation.
.google.cloud.datalabeling.v1beta1.AnnotationSentiment annotation_sentiment = 6;- Specified by:
getAnnotationSentimentValuein interfaceAnnotationOrBuilder- Returns:
- The enum numeric value on the wire for annotationSentiment.
-
setAnnotationSentimentValue
public Annotation.Builder setAnnotationSentimentValue(int value)
Output only. Sentiment for this annotation.
.google.cloud.datalabeling.v1beta1.AnnotationSentiment annotation_sentiment = 6;- Parameters:
value- The enum numeric value on the wire for annotationSentiment to set.- Returns:
- This builder for chaining.
-
getAnnotationSentiment
public AnnotationSentiment getAnnotationSentiment()
Output only. Sentiment for this annotation.
.google.cloud.datalabeling.v1beta1.AnnotationSentiment annotation_sentiment = 6;- Specified by:
getAnnotationSentimentin interfaceAnnotationOrBuilder- Returns:
- The annotationSentiment.
-
setAnnotationSentiment
public Annotation.Builder setAnnotationSentiment(AnnotationSentiment value)
Output only. Sentiment for this annotation.
.google.cloud.datalabeling.v1beta1.AnnotationSentiment annotation_sentiment = 6;- Parameters:
value- The annotationSentiment to set.- Returns:
- This builder for chaining.
-
clearAnnotationSentiment
public Annotation.Builder clearAnnotationSentiment()
Output only. Sentiment for this annotation.
.google.cloud.datalabeling.v1beta1.AnnotationSentiment annotation_sentiment = 6;- Returns:
- This builder for chaining.
-
setUnknownFields
public final Annotation.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
- Specified by:
setUnknownFieldsin interfacecom.google.protobuf.Message.Builder- Overrides:
setUnknownFieldsin classcom.google.protobuf.GeneratedMessageV3.Builder<Annotation.Builder>
-
mergeUnknownFields
public final Annotation.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
- Specified by:
mergeUnknownFieldsin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeUnknownFieldsin classcom.google.protobuf.GeneratedMessageV3.Builder<Annotation.Builder>
-
-