Class CreateDraftRequest.Builder (0.6.0)

public static final class CreateDraftRequest.Builder extends GeneratedMessageV3.Builder<CreateDraftRequest.Builder> implements CreateDraftRequestOrBuilder

Message for creating a Draft.

Protobuf type google.cloud.visionai.v1.CreateDraftRequest

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public CreateDraftRequest.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
CreateDraftRequest.Builder
Overrides

build()

public CreateDraftRequest build()
Returns
Type Description
CreateDraftRequest

buildPartial()

public CreateDraftRequest buildPartial()
Returns
Type Description
CreateDraftRequest

clear()

public CreateDraftRequest.Builder clear()
Returns
Type Description
CreateDraftRequest.Builder
Overrides

clearDraft()

public CreateDraftRequest.Builder clearDraft()

Required. The resource being created.

.google.cloud.visionai.v1.Draft draft = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
CreateDraftRequest.Builder

clearDraftId()

public CreateDraftRequest.Builder clearDraftId()

Required. Id of the requesting object.

string draft_id = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
CreateDraftRequest.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public CreateDraftRequest.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
CreateDraftRequest.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public CreateDraftRequest.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
CreateDraftRequest.Builder
Overrides

clearParent()

public CreateDraftRequest.Builder clearParent()

Required. Value for parent.

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

Returns
Type Description
CreateDraftRequest.Builder

This builder for chaining.

clearRequestId()

public CreateDraftRequest.Builder clearRequestId()

Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request.

For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments.

The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).

string request_id = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
CreateDraftRequest.Builder

This builder for chaining.

clone()

public CreateDraftRequest.Builder clone()
Returns
Type Description
CreateDraftRequest.Builder
Overrides

getDefaultInstanceForType()

public CreateDraftRequest getDefaultInstanceForType()
Returns
Type Description
CreateDraftRequest

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getDraft()

public Draft getDraft()

Required. The resource being created.

.google.cloud.visionai.v1.Draft draft = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
Draft

The draft.

getDraftBuilder()

public Draft.Builder getDraftBuilder()

Required. The resource being created.

.google.cloud.visionai.v1.Draft draft = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
Draft.Builder

getDraftId()

public String getDraftId()

Required. Id of the requesting object.

string draft_id = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
String

The draftId.

getDraftIdBytes()

public ByteString getDraftIdBytes()

Required. Id of the requesting object.

string draft_id = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ByteString

The bytes for draftId.

getDraftOrBuilder()

public DraftOrBuilder getDraftOrBuilder()

Required. The resource being created.

.google.cloud.visionai.v1.Draft draft = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
DraftOrBuilder

getParent()

public String getParent()

Required. Value for parent.

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

Returns
Type Description
String

The parent.

getParentBytes()

public ByteString getParentBytes()

Required. Value for parent.

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

Returns
Type Description
ByteString

The bytes for parent.

getRequestId()

public String getRequestId()

Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request.

For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments.

The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).

string request_id = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The requestId.

getRequestIdBytes()

public ByteString getRequestIdBytes()

Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request.

For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments.

The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).

string request_id = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for requestId.

hasDraft()

public boolean hasDraft()

Required. The resource being created.

.google.cloud.visionai.v1.Draft draft = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
boolean

Whether the draft field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeDraft(Draft value)

public CreateDraftRequest.Builder mergeDraft(Draft value)

Required. The resource being created.

.google.cloud.visionai.v1.Draft draft = 3 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value Draft
Returns
Type Description
CreateDraftRequest.Builder

mergeFrom(CreateDraftRequest other)

public CreateDraftRequest.Builder mergeFrom(CreateDraftRequest other)
Parameter
Name Description
other CreateDraftRequest
Returns
Type Description
CreateDraftRequest.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public CreateDraftRequest.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
CreateDraftRequest.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public CreateDraftRequest.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
CreateDraftRequest.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final CreateDraftRequest.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
CreateDraftRequest.Builder
Overrides

setDraft(Draft value)

public CreateDraftRequest.Builder setDraft(Draft value)

Required. The resource being created.

.google.cloud.visionai.v1.Draft draft = 3 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value Draft
Returns
Type Description
CreateDraftRequest.Builder

setDraft(Draft.Builder builderForValue)

public CreateDraftRequest.Builder setDraft(Draft.Builder builderForValue)

Required. The resource being created.

.google.cloud.visionai.v1.Draft draft = 3 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
builderForValue Draft.Builder
Returns
Type Description
CreateDraftRequest.Builder

setDraftId(String value)

public CreateDraftRequest.Builder setDraftId(String value)

Required. Id of the requesting object.

string draft_id = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value String

The draftId to set.

Returns
Type Description
CreateDraftRequest.Builder

This builder for chaining.

setDraftIdBytes(ByteString value)

public CreateDraftRequest.Builder setDraftIdBytes(ByteString value)

Required. Id of the requesting object.

string draft_id = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value ByteString

The bytes for draftId to set.

Returns
Type Description
CreateDraftRequest.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public CreateDraftRequest.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
CreateDraftRequest.Builder
Overrides

setParent(String value)

public CreateDraftRequest.Builder setParent(String value)

Required. Value for parent.

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

Parameter
Name Description
value String

The parent to set.

Returns
Type Description
CreateDraftRequest.Builder

This builder for chaining.

setParentBytes(ByteString value)

public CreateDraftRequest.Builder setParentBytes(ByteString value)

Required. Value for parent.

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

Parameter
Name Description
value ByteString

The bytes for parent to set.

Returns
Type Description
CreateDraftRequest.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public CreateDraftRequest.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
CreateDraftRequest.Builder
Overrides

setRequestId(String value)

public CreateDraftRequest.Builder setRequestId(String value)

Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request.

For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments.

The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).

string request_id = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The requestId to set.

Returns
Type Description
CreateDraftRequest.Builder

This builder for chaining.

setRequestIdBytes(ByteString value)

public CreateDraftRequest.Builder setRequestIdBytes(ByteString value)

Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request.

For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments.

The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).

string request_id = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for requestId to set.

Returns
Type Description
CreateDraftRequest.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final CreateDraftRequest.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
CreateDraftRequest.Builder
Overrides