Class Annotation.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.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.GeneratedMessage.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 type
google.cloud.datalabeling.v1beta1.Annotation-
Method Summary
Modifier and TypeMethodDescriptionbuild()clear()Output only.Output only.Output only.Output only.Output only.Output only.Output only.Output only.Output only.intOutput only.Output only.intOutput only.Output only.Output only.Output only.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorgetName()Output only.com.google.protobuf.ByteStringOutput only.booleanOutput only.booleanOutput only.protected com.google.protobuf.GeneratedMessage.FieldAccessorTablefinal booleanOutput only.Output only.mergeFrom(Annotation other) mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) Output only.setAnnotationMetadata(AnnotationMetadata.Builder builderForValue) Output only.Output only.setAnnotationSentimentValue(int value) Output only.Output only.setAnnotationSourceValue(int value) Output only.Output only.setAnnotationValue(AnnotationValue.Builder builderForValue) Output only.Output only.setNameBytes(com.google.protobuf.ByteString value) Output only.Methods inherited from class com.google.protobuf.GeneratedMessage.Builder
addRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownFields, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFields, setUnknownFieldSetBuilder, setUnknownFieldsProto3Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFromMethods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFromMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessage.Builder<Annotation.Builder>
-
clear
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessage.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.GeneratedMessage.Builder<Annotation.Builder>
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
mergeFrom
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<Annotation.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage.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
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
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
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
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
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
Output only. The source of the annotation.
.google.cloud.datalabeling.v1beta1.AnnotationSource annotation_source = 2;- Specified by:
getAnnotationSourcein interfaceAnnotationOrBuilder- Returns:
- The annotationSource.
-
setAnnotationSource
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
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
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
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
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
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
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
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
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
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
Output only. Annotation metadata, including information like votes for labels.
.google.cloud.datalabeling.v1beta1.AnnotationMetadata annotation_metadata = 4; -
setAnnotationMetadata
Output only. Annotation metadata, including information like votes for labels.
.google.cloud.datalabeling.v1beta1.AnnotationMetadata annotation_metadata = 4; -
mergeAnnotationMetadata
Output only. Annotation metadata, including information like votes for labels.
.google.cloud.datalabeling.v1beta1.AnnotationMetadata annotation_metadata = 4; -
clearAnnotationMetadata
Output only. Annotation metadata, including information like votes for labels.
.google.cloud.datalabeling.v1beta1.AnnotationMetadata annotation_metadata = 4; -
getAnnotationMetadataBuilder
Output only. Annotation metadata, including information like votes for labels.
.google.cloud.datalabeling.v1beta1.AnnotationMetadata annotation_metadata = 4; -
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
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
Output only. Sentiment for this annotation.
.google.cloud.datalabeling.v1beta1.AnnotationSentiment annotation_sentiment = 6;- Specified by:
getAnnotationSentimentin interfaceAnnotationOrBuilder- Returns:
- The annotationSentiment.
-
setAnnotationSentiment
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
Output only. Sentiment for this annotation.
.google.cloud.datalabeling.v1beta1.AnnotationSentiment annotation_sentiment = 6;- Returns:
- This builder for chaining.
-