Class CreateAnnotationRequest (0.6.0)

publicfinalclass CreateAnnotationRequestextendsGeneratedMessageV3implementsCreateAnnotationRequestOrBuilder

Request message for CreateAnnotation.

Protobuf type google.cloud.visionai.v1.CreateAnnotationRequest

Inherited Members

com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT)
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT,int)
com.google.protobuf.GeneratedMessageV3.<T>emptyList(java.lang.Class<T>)
com.google.protobuf.GeneratedMessageV3.internalGetMapFieldReflection(int)

Static Fields

ANNOTATION_FIELD_NUMBER

publicstaticfinalintANNOTATION_FIELD_NUMBER
Field Value
Type Description
int

ANNOTATION_ID_FIELD_NUMBER

publicstaticfinalintANNOTATION_ID_FIELD_NUMBER
Field Value
Type Description
int

PARENT_FIELD_NUMBER

publicstaticfinalintPARENT_FIELD_NUMBER
Field Value
Type Description
int

Static Methods

getDefaultInstance()

publicstaticCreateAnnotationRequestgetDefaultInstance()
Returns
Type Description
CreateAnnotationRequest

getDescriptor()

publicstaticfinalDescriptors.DescriptorgetDescriptor()
Returns
Type Description
Descriptor

newBuilder()

publicstaticCreateAnnotationRequest.BuildernewBuilder()
Returns
Type Description
CreateAnnotationRequest.Builder

newBuilder(CreateAnnotationRequest prototype)

publicstaticCreateAnnotationRequest.BuildernewBuilder(CreateAnnotationRequestprototype)
Parameter
Name Description
prototype CreateAnnotationRequest
Returns
Type Description
CreateAnnotationRequest.Builder

parseDelimitedFrom(InputStream input)

publicstaticCreateAnnotationRequestparseDelimitedFrom(InputStreaminput)
Parameter
Name Description
input InputStream
Returns
Type Description
CreateAnnotationRequest
Exceptions
Type Description
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

publicstaticCreateAnnotationRequestparseDelimitedFrom(InputStreaminput,ExtensionRegistryLiteextensionRegistry)
Parameters
Name Description
input InputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
CreateAnnotationRequest
Exceptions
Type Description
IOException

parseFrom(byte[] data)

publicstaticCreateAnnotationRequestparseFrom(byte[]data)
Parameter
Name Description
data byte[]
Returns
Type Description
CreateAnnotationRequest
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

publicstaticCreateAnnotationRequestparseFrom(byte[]data,ExtensionRegistryLiteextensionRegistry)
Parameters
Name Description
data byte[]
extensionRegistry ExtensionRegistryLite
Returns
Type Description
CreateAnnotationRequest
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteString data)

publicstaticCreateAnnotationRequestparseFrom(ByteStringdata)
Parameter
Name Description
data ByteString
Returns
Type Description
CreateAnnotationRequest
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

publicstaticCreateAnnotationRequestparseFrom(ByteStringdata,ExtensionRegistryLiteextensionRegistry)
Parameters
Name Description
data ByteString
extensionRegistry ExtensionRegistryLite
Returns
Type Description
CreateAnnotationRequest
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

publicstaticCreateAnnotationRequestparseFrom(CodedInputStreaminput)
Parameter
Name Description
input CodedInputStream
Returns
Type Description
CreateAnnotationRequest
Exceptions
Type Description
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

publicstaticCreateAnnotationRequestparseFrom(CodedInputStreaminput,ExtensionRegistryLiteextensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
CreateAnnotationRequest
Exceptions
Type Description
IOException

parseFrom(InputStream input)

publicstaticCreateAnnotationRequestparseFrom(InputStreaminput)
Parameter
Name Description
input InputStream
Returns
Type Description
CreateAnnotationRequest
Exceptions
Type Description
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

publicstaticCreateAnnotationRequestparseFrom(InputStreaminput,ExtensionRegistryLiteextensionRegistry)
Parameters
Name Description
input InputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
CreateAnnotationRequest
Exceptions
Type Description
IOException

parseFrom(ByteBuffer data)

publicstaticCreateAnnotationRequestparseFrom(ByteBufferdata)
Parameter
Name Description
data ByteBuffer
Returns
Type Description
CreateAnnotationRequest
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

publicstaticCreateAnnotationRequestparseFrom(ByteBufferdata,ExtensionRegistryLiteextensionRegistry)
Parameters
Name Description
data ByteBuffer
extensionRegistry ExtensionRegistryLite
Returns
Type Description
CreateAnnotationRequest
Exceptions
Type Description
InvalidProtocolBufferException

parser()

publicstaticParser<CreateAnnotationRequest>parser()
Returns
Type Description
Parser<CreateAnnotationRequest>

Methods

equals(Object obj)

publicbooleanequals(Objectobj)
Parameter
Name Description
obj Object
Returns
Type Description
boolean
Overrides

getAnnotation()

publicAnnotationgetAnnotation()

Required. The annotation to create.

.google.cloud.visionai.v1.Annotation annotation = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
Annotation

The annotation.

getAnnotationId()

publicStringgetAnnotationId()

Optional. The ID to use for the annotation, which will become the final component of the annotation's resource name if user choose to specify. Otherwise, annotation id will be generated by system.

This value should be up to 63 characters, and valid characters are /a-z-/. The first character must be a letter, the last could be a letter or a number.

optional string annotation_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The annotationId.

getAnnotationIdBytes()

publicByteStringgetAnnotationIdBytes()

Optional. The ID to use for the annotation, which will become the final component of the annotation's resource name if user choose to specify. Otherwise, annotation id will be generated by system.

This value should be up to 63 characters, and valid characters are /a-z-/. The first character must be a letter, the last could be a letter or a number.

optional string annotation_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for annotationId.

getAnnotationOrBuilder()

publicAnnotationOrBuildergetAnnotationOrBuilder()

Required. The annotation to create.

.google.cloud.visionai.v1.Annotation annotation = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
AnnotationOrBuilder

getDefaultInstanceForType()

publicCreateAnnotationRequestgetDefaultInstanceForType()
Returns
Type Description
CreateAnnotationRequest

getParent()

publicStringgetParent()

Required. The parent resource where this annotation will be created. Format: projects/{project_number}/locations/{location_id}/corpora/{corpus_id}/assets/{asset_id}

string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
String

The parent.

getParentBytes()

publicByteStringgetParentBytes()

Required. The parent resource where this annotation will be created. Format: projects/{project_number}/locations/{location_id}/corpora/{corpus_id}/assets/{asset_id}

string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
ByteString

The bytes for parent.

getParserForType()

publicParser<CreateAnnotationRequest>getParserForType()
Returns
Type Description
Parser<CreateAnnotationRequest>
Overrides

getSerializedSize()

publicintgetSerializedSize()
Returns
Type Description
int
Overrides

hasAnnotation()

publicbooleanhasAnnotation()

Required. The annotation to create.

.google.cloud.visionai.v1.Annotation annotation = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
boolean

Whether the annotation field is set.

hasAnnotationId()

publicbooleanhasAnnotationId()

Optional. The ID to use for the annotation, which will become the final component of the annotation's resource name if user choose to specify. Otherwise, annotation id will be generated by system.

This value should be up to 63 characters, and valid characters are /a-z-/. The first character must be a letter, the last could be a letter or a number.

optional string annotation_id = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the annotationId field is set.

hashCode()

publicinthashCode()
Returns
Type Description
int
Overrides

internalGetFieldAccessorTable()

protectedGeneratedMessageV3.FieldAccessorTableinternalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

publicfinalbooleanisInitialized()
Returns
Type Description
boolean
Overrides

newBuilderForType()

publicCreateAnnotationRequest.BuildernewBuilderForType()
Returns
Type Description
CreateAnnotationRequest.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protectedCreateAnnotationRequest.BuildernewBuilderForType(GeneratedMessageV3.BuilderParentparent)
Parameter
Name Description
parent BuilderParent
Returns
Type Description
CreateAnnotationRequest.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protectedObjectnewInstance(GeneratedMessageV3.UnusedPrivateParameterunused)
Parameter
Name Description
unused UnusedPrivateParameter
Returns
Type Description
Object
Overrides

toBuilder()

publicCreateAnnotationRequest.BuildertoBuilder()
Returns
Type Description
CreateAnnotationRequest.Builder

writeTo(CodedOutputStream output)

publicvoidwriteTo(CodedOutputStreamoutput)
Parameter
Name Description
output CodedOutputStream
Overrides
Exceptions
Type Description
IOException

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025年10月30日 UTC.