public static final class Operation.Builder extends GeneratedMessageV3.Builder<Operation.Builder> implements OperationOrBuilder
This resource represents a long-running operation that is the result of a network API call.
Protobuf type google.longrunning.Operation
Inheritance
Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessageV3.Builder > Operation.BuilderImplements
OperationOrBuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Type | Description |
Descriptor |
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public Operation.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Name | Description |
field | FieldDescriptor |
value | Object |
Type | Description |
Operation.Builder |
build()
public Operation build()
Type | Description |
Operation |
buildPartial()
public Operation buildPartial()
Type | Description |
Operation |
clear()
public Operation.Builder clear()
Type | Description |
Operation.Builder |
clearDone()
public Operation.Builder clearDone()
If the value is false
, it means the operation is still in progress.
If true
, the operation is completed, and either error
or response
is
available.
bool done = 3;
Type | Description |
Operation.Builder | This builder for chaining. |
clearError()
public Operation.Builder clearError()
The error result of the operation in case of failure or cancellation.
.google.rpc.Status error = 4;
Type | Description |
Operation.Builder |
clearField(Descriptors.FieldDescriptor field)
public Operation.Builder clearField(Descriptors.FieldDescriptor field)
Name | Description |
field | FieldDescriptor |
Type | Description |
Operation.Builder |
clearMetadata()
public Operation.Builder clearMetadata()
Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
.google.protobuf.Any metadata = 2;
Type | Description |
Operation.Builder |
clearName()
public Operation.Builder clearName()
The server-assigned name, which is only unique within the same service that
originally returns it. If you use the default HTTP mapping, the
name
should be a resource name ending with operations/{unique_id}
.
string name = 1;
Type | Description |
Operation.Builder | This builder for chaining. |
clearOneof(Descriptors.OneofDescriptor oneof)
public Operation.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Name | Description |
oneof | OneofDescriptor |
Type | Description |
Operation.Builder |
clearResponse()
public Operation.Builder clearResponse()
The normal response of the operation in case of success. If the original
method returns no data on success, such as Delete
, the response is
google.protobuf.Empty
. If the original method is standard
Get
/Create
/Update
, the response should be the resource. For other
methods, the response should have the type XxxResponse
, where Xxx
is the original method name. For example, if the original method name
is TakeSnapshot()
, the inferred response type is
TakeSnapshotResponse
.
.google.protobuf.Any response = 5;
Type | Description |
Operation.Builder |
clearResult()
public Operation.Builder clearResult()
Type | Description |
Operation.Builder |
clone()
public Operation.Builder clone()
Type | Description |
Operation.Builder |
getDefaultInstanceForType()
public Operation getDefaultInstanceForType()
Type | Description |
Operation |
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Type | Description |
Descriptor |
getDone()
public boolean getDone()
If the value is false
, it means the operation is still in progress.
If true
, the operation is completed, and either error
or response
is
available.
bool done = 3;
Type | Description |
boolean | The done. |
getError()
public Status getError()
The error result of the operation in case of failure or cancellation.
.google.rpc.Status error = 4;
Type | Description |
Status | The error. |
getErrorBuilder()
public Status.Builder getErrorBuilder()
The error result of the operation in case of failure or cancellation.
.google.rpc.Status error = 4;
Type | Description |
Status.Builder |
getErrorOrBuilder()
public StatusOrBuilder getErrorOrBuilder()
The error result of the operation in case of failure or cancellation.
.google.rpc.Status error = 4;
Type | Description |
StatusOrBuilder |
getMetadata()
public Any getMetadata()
Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
.google.protobuf.Any metadata = 2;
Type | Description |
Any | The metadata. |
getMetadataBuilder()
public Any.Builder getMetadataBuilder()
Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
.google.protobuf.Any metadata = 2;
Type | Description |
Builder |
getMetadataOrBuilder()
public AnyOrBuilder getMetadataOrBuilder()
Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
.google.protobuf.Any metadata = 2;
Type | Description |
AnyOrBuilder |
getName()
public String getName()
The server-assigned name, which is only unique within the same service that
originally returns it. If you use the default HTTP mapping, the
name
should be a resource name ending with operations/{unique_id}
.
string name = 1;
Type | Description |
String | The name. |
getNameBytes()
public ByteString getNameBytes()
The server-assigned name, which is only unique within the same service that
originally returns it. If you use the default HTTP mapping, the
name
should be a resource name ending with operations/{unique_id}
.
string name = 1;
Type | Description |
ByteString | The bytes for name. |
getResponse()
public Any getResponse()
The normal response of the operation in case of success. If the original
method returns no data on success, such as Delete
, the response is
google.protobuf.Empty
. If the original method is standard
Get
/Create
/Update
, the response should be the resource. For other
methods, the response should have the type XxxResponse
, where Xxx
is the original method name. For example, if the original method name
is TakeSnapshot()
, the inferred response type is
TakeSnapshotResponse
.
.google.protobuf.Any response = 5;
Type | Description |
Any | The response. |
getResponseBuilder()
public Any.Builder getResponseBuilder()
The normal response of the operation in case of success. If the original
method returns no data on success, such as Delete
, the response is
google.protobuf.Empty
. If the original method is standard
Get
/Create
/Update
, the response should be the resource. For other
methods, the response should have the type XxxResponse
, where Xxx
is the original method name. For example, if the original method name
is TakeSnapshot()
, the inferred response type is
TakeSnapshotResponse
.
.google.protobuf.Any response = 5;
Type | Description |
Builder |
getResponseOrBuilder()
public AnyOrBuilder getResponseOrBuilder()
The normal response of the operation in case of success. If the original
method returns no data on success, such as Delete
, the response is
google.protobuf.Empty
. If the original method is standard
Get
/Create
/Update
, the response should be the resource. For other
methods, the response should have the type XxxResponse
, where Xxx
is the original method name. For example, if the original method name
is TakeSnapshot()
, the inferred response type is
TakeSnapshotResponse
.
.google.protobuf.Any response = 5;
Type | Description |
AnyOrBuilder |
getResultCase()
public Operation.ResultCase getResultCase()
Type | Description |
Operation.ResultCase |
hasError()
public boolean hasError()
The error result of the operation in case of failure or cancellation.
.google.rpc.Status error = 4;
Type | Description |
boolean | Whether the error field is set. |
hasMetadata()
public boolean hasMetadata()
Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
.google.protobuf.Any metadata = 2;
Type | Description |
boolean | Whether the metadata field is set. |
hasResponse()
public boolean hasResponse()
The normal response of the operation in case of success. If the original
method returns no data on success, such as Delete
, the response is
google.protobuf.Empty
. If the original method is standard
Get
/Create
/Update
, the response should be the resource. For other
methods, the response should have the type XxxResponse
, where Xxx
is the original method name. For example, if the original method name
is TakeSnapshot()
, the inferred response type is
TakeSnapshotResponse
.
.google.protobuf.Any response = 5;
Type | Description |
boolean | Whether the response field is set. |
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Type | Description |
FieldAccessorTable |
isInitialized()
public final boolean isInitialized()
Type | Description |
boolean |
mergeError(Status value)
public Operation.Builder mergeError(Status value)
The error result of the operation in case of failure or cancellation.
.google.rpc.Status error = 4;
Name | Description |
value | Status |
Type | Description |
Operation.Builder |
mergeFrom(Operation other)
public Operation.Builder mergeFrom(Operation other)
Name | Description |
other | Operation |
Type | Description |
Operation.Builder |
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public Operation.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Name | Description |
input | CodedInputStream |
extensionRegistry | ExtensionRegistryLite |
Type | Description |
Operation.Builder |
Type | Description |
IOException |
mergeFrom(Message other)
public Operation.Builder mergeFrom(Message other)
Name | Description |
other | Message |
Type | Description |
Operation.Builder |
mergeMetadata(Any value)
public Operation.Builder mergeMetadata(Any value)
Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
.google.protobuf.Any metadata = 2;
Name | Description |
value | Any |
Type | Description |
Operation.Builder |
mergeResponse(Any value)
public Operation.Builder mergeResponse(Any value)
The normal response of the operation in case of success. If the original
method returns no data on success, such as Delete
, the response is
google.protobuf.Empty
. If the original method is standard
Get
/Create
/Update
, the response should be the resource. For other
methods, the response should have the type XxxResponse
, where Xxx
is the original method name. For example, if the original method name
is TakeSnapshot()
, the inferred response type is
TakeSnapshotResponse
.
.google.protobuf.Any response = 5;
Name | Description |
value | Any |
Type | Description |
Operation.Builder |
mergeUnknownFields(UnknownFieldSet unknownFields)
public final Operation.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Name | Description |
unknownFields | UnknownFieldSet |
Type | Description |
Operation.Builder |
setDone(boolean value)
public Operation.Builder setDone(boolean value)
If the value is false
, it means the operation is still in progress.
If true
, the operation is completed, and either error
or response
is
available.
bool done = 3;
Name | Description |
value | boolean The done to set. |
Type | Description |
Operation.Builder | This builder for chaining. |
setError(Status value)
public Operation.Builder setError(Status value)
The error result of the operation in case of failure or cancellation.
.google.rpc.Status error = 4;
Name | Description |
value | Status |
Type | Description |
Operation.Builder |
setError(Status.Builder builderForValue)
public Operation.Builder setError(Status.Builder builderForValue)
The error result of the operation in case of failure or cancellation.
.google.rpc.Status error = 4;
Name | Description |
builderForValue | Status.Builder |
Type | Description |
Operation.Builder |
setField(Descriptors.FieldDescriptor field, Object value)
public Operation.Builder setField(Descriptors.FieldDescriptor field, Object value)
Name | Description |
field | FieldDescriptor |
value | Object |
Type | Description |
Operation.Builder |
setMetadata(Any value)
public Operation.Builder setMetadata(Any value)
Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
.google.protobuf.Any metadata = 2;
Name | Description |
value | Any |
Type | Description |
Operation.Builder |
setMetadata(Any.Builder builderForValue)
public Operation.Builder setMetadata(Any.Builder builderForValue)
Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
.google.protobuf.Any metadata = 2;
Name | Description |
builderForValue | Builder |
Type | Description |
Operation.Builder |
setName(String value)
public Operation.Builder setName(String value)
The server-assigned name, which is only unique within the same service that
originally returns it. If you use the default HTTP mapping, the
name
should be a resource name ending with operations/{unique_id}
.
string name = 1;
Name | Description |
value | String The name to set. |
Type | Description |
Operation.Builder | This builder for chaining. |
setNameBytes(ByteString value)
public Operation.Builder setNameBytes(ByteString value)
The server-assigned name, which is only unique within the same service that
originally returns it. If you use the default HTTP mapping, the
name
should be a resource name ending with operations/{unique_id}
.
string name = 1;
Name | Description |
value | ByteString The bytes for name to set. |
Type | Description |
Operation.Builder | This builder for chaining. |
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public Operation.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Name | Description |
field | FieldDescriptor |
index | int |
value | Object |
Type | Description |
Operation.Builder |
setResponse(Any value)
public Operation.Builder setResponse(Any value)
The normal response of the operation in case of success. If the original
method returns no data on success, such as Delete
, the response is
google.protobuf.Empty
. If the original method is standard
Get
/Create
/Update
, the response should be the resource. For other
methods, the response should have the type XxxResponse
, where Xxx
is the original method name. For example, if the original method name
is TakeSnapshot()
, the inferred response type is
TakeSnapshotResponse
.
.google.protobuf.Any response = 5;
Name | Description |
value | Any |
Type | Description |
Operation.Builder |
setResponse(Any.Builder builderForValue)
public Operation.Builder setResponse(Any.Builder builderForValue)
The normal response of the operation in case of success. If the original
method returns no data on success, such as Delete
, the response is
google.protobuf.Empty
. If the original method is standard
Get
/Create
/Update
, the response should be the resource. For other
methods, the response should have the type XxxResponse
, where Xxx
is the original method name. For example, if the original method name
is TakeSnapshot()
, the inferred response type is
TakeSnapshotResponse
.
.google.protobuf.Any response = 5;
Name | Description |
builderForValue | Builder |
Type | Description |
Operation.Builder |
setUnknownFields(UnknownFieldSet unknownFields)
public final Operation.Builder setUnknownFields(UnknownFieldSet unknownFields)
Name | Description |
unknownFields | UnknownFieldSet |
Type | Description |
Operation.Builder |