Class UpdateObjectRequest.Builder (2.22.3)

public static final class UpdateObjectRequest.Builder extends GeneratedMessageV3.Builder<UpdateObjectRequest.Builder> implements UpdateObjectRequestOrBuilder

Request message for UpdateObject.

Protobuf type google.storage.v2.UpdateObjectRequest

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public UpdateObjectRequest.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
UpdateObjectRequest.Builder
Overrides

build()

public UpdateObjectRequest build()
Returns
TypeDescription
UpdateObjectRequest

buildPartial()

public UpdateObjectRequest buildPartial()
Returns
TypeDescription
UpdateObjectRequest

clear()

public UpdateObjectRequest.Builder clear()
Returns
TypeDescription
UpdateObjectRequest.Builder
Overrides

clearCommonObjectRequestParams()

public UpdateObjectRequest.Builder clearCommonObjectRequestParams()

A set of parameters common to Storage API requests concerning an object.

.google.storage.v2.CommonObjectRequestParams common_object_request_params = 8;

Returns
TypeDescription
UpdateObjectRequest.Builder

clearField(Descriptors.FieldDescriptor field)

public UpdateObjectRequest.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
UpdateObjectRequest.Builder
Overrides

clearIfGenerationMatch()

public UpdateObjectRequest.Builder clearIfGenerationMatch()

Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.

optional int64 if_generation_match = 2;

Returns
TypeDescription
UpdateObjectRequest.Builder

This builder for chaining.

clearIfGenerationNotMatch()

public UpdateObjectRequest.Builder clearIfGenerationNotMatch()

Makes the operation conditional on whether the object's live generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.

optional int64 if_generation_not_match = 3;

Returns
TypeDescription
UpdateObjectRequest.Builder

This builder for chaining.

clearIfMetagenerationMatch()

public UpdateObjectRequest.Builder clearIfMetagenerationMatch()

Makes the operation conditional on whether the object's current metageneration matches the given value.

optional int64 if_metageneration_match = 4;

Returns
TypeDescription
UpdateObjectRequest.Builder

This builder for chaining.

clearIfMetagenerationNotMatch()

public UpdateObjectRequest.Builder clearIfMetagenerationNotMatch()

Makes the operation conditional on whether the object's current metageneration does not match the given value.

optional int64 if_metageneration_not_match = 5;

Returns
TypeDescription
UpdateObjectRequest.Builder

This builder for chaining.

clearObject()

public UpdateObjectRequest.Builder clearObject()

Required. The object to update. The object's bucket and name fields are used to identify the object to update. If present, the object's generation field selects a specific revision of this object whose metadata should be updated. Otherwise, assumes the live version of the object.

.google.storage.v2.Object object = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
UpdateObjectRequest.Builder

clearOneof(Descriptors.OneofDescriptor oneof)

public UpdateObjectRequest.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
UpdateObjectRequest.Builder
Overrides

clearPredefinedAcl()

public UpdateObjectRequest.Builder clearPredefinedAcl()

Apply a predefined set of access controls to this object. Valid values are "authenticatedRead", "bucketOwnerFullControl", "bucketOwnerRead", "private", "projectPrivate", or "publicRead".

string predefined_acl = 10;

Returns
TypeDescription
UpdateObjectRequest.Builder

This builder for chaining.

clearUpdateMask()

public UpdateObjectRequest.Builder clearUpdateMask()

Required. List of fields to be updated. To specify ALL fields, equivalent to the JSON API's "update" function, specify a single field with the value . Note: not recommended. If a new field is introduced at a later time, an older client updating with the may accidentally reset the new field's value. Not specifying any fields is an error.

.google.protobuf.FieldMask update_mask = 7 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
UpdateObjectRequest.Builder

clone()

public UpdateObjectRequest.Builder clone()
Returns
TypeDescription
UpdateObjectRequest.Builder
Overrides

getCommonObjectRequestParams()

public CommonObjectRequestParams getCommonObjectRequestParams()

A set of parameters common to Storage API requests concerning an object.

.google.storage.v2.CommonObjectRequestParams common_object_request_params = 8;

Returns
TypeDescription
CommonObjectRequestParams

The commonObjectRequestParams.

getCommonObjectRequestParamsBuilder()

public CommonObjectRequestParams.Builder getCommonObjectRequestParamsBuilder()

A set of parameters common to Storage API requests concerning an object.

.google.storage.v2.CommonObjectRequestParams common_object_request_params = 8;

Returns
TypeDescription
CommonObjectRequestParams.Builder

getCommonObjectRequestParamsOrBuilder()

public CommonObjectRequestParamsOrBuilder getCommonObjectRequestParamsOrBuilder()

A set of parameters common to Storage API requests concerning an object.

.google.storage.v2.CommonObjectRequestParams common_object_request_params = 8;

Returns
TypeDescription
CommonObjectRequestParamsOrBuilder

getDefaultInstanceForType()

public UpdateObjectRequest getDefaultInstanceForType()
Returns
TypeDescription
UpdateObjectRequest

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getIfGenerationMatch()

public long getIfGenerationMatch()

Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.

optional int64 if_generation_match = 2;

Returns
TypeDescription
long

The ifGenerationMatch.

getIfGenerationNotMatch()

public long getIfGenerationNotMatch()

Makes the operation conditional on whether the object's live generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.

optional int64 if_generation_not_match = 3;

Returns
TypeDescription
long

The ifGenerationNotMatch.

getIfMetagenerationMatch()

public long getIfMetagenerationMatch()

Makes the operation conditional on whether the object's current metageneration matches the given value.

optional int64 if_metageneration_match = 4;

Returns
TypeDescription
long

The ifMetagenerationMatch.

getIfMetagenerationNotMatch()

public long getIfMetagenerationNotMatch()

Makes the operation conditional on whether the object's current metageneration does not match the given value.

optional int64 if_metageneration_not_match = 5;

Returns
TypeDescription
long

The ifMetagenerationNotMatch.

getObject()

public Object getObject()

Required. The object to update. The object's bucket and name fields are used to identify the object to update. If present, the object's generation field selects a specific revision of this object whose metadata should be updated. Otherwise, assumes the live version of the object.

.google.storage.v2.Object object = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
Object

The object.

getObjectBuilder()

public Object.Builder getObjectBuilder()

Required. The object to update. The object's bucket and name fields are used to identify the object to update. If present, the object's generation field selects a specific revision of this object whose metadata should be updated. Otherwise, assumes the live version of the object.

.google.storage.v2.Object object = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
Object.Builder

getObjectOrBuilder()

public ObjectOrBuilder getObjectOrBuilder()

Required. The object to update. The object's bucket and name fields are used to identify the object to update. If present, the object's generation field selects a specific revision of this object whose metadata should be updated. Otherwise, assumes the live version of the object.

.google.storage.v2.Object object = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
ObjectOrBuilder

getPredefinedAcl()

public String getPredefinedAcl()

Apply a predefined set of access controls to this object. Valid values are "authenticatedRead", "bucketOwnerFullControl", "bucketOwnerRead", "private", "projectPrivate", or "publicRead".

string predefined_acl = 10;

Returns
TypeDescription
String

The predefinedAcl.

getPredefinedAclBytes()

public ByteString getPredefinedAclBytes()

Apply a predefined set of access controls to this object. Valid values are "authenticatedRead", "bucketOwnerFullControl", "bucketOwnerRead", "private", "projectPrivate", or "publicRead".

string predefined_acl = 10;

Returns
TypeDescription
ByteString

The bytes for predefinedAcl.

getUpdateMask()

public FieldMask getUpdateMask()

Required. List of fields to be updated. To specify ALL fields, equivalent to the JSON API's "update" function, specify a single field with the value . Note: not recommended. If a new field is introduced at a later time, an older client updating with the may accidentally reset the new field's value. Not specifying any fields is an error.

.google.protobuf.FieldMask update_mask = 7 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
FieldMask

The updateMask.

getUpdateMaskBuilder()

public FieldMask.Builder getUpdateMaskBuilder()

Required. List of fields to be updated. To specify ALL fields, equivalent to the JSON API's "update" function, specify a single field with the value . Note: not recommended. If a new field is introduced at a later time, an older client updating with the may accidentally reset the new field's value. Not specifying any fields is an error.

.google.protobuf.FieldMask update_mask = 7 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
Builder

getUpdateMaskOrBuilder()

public FieldMaskOrBuilder getUpdateMaskOrBuilder()

Required. List of fields to be updated. To specify ALL fields, equivalent to the JSON API's "update" function, specify a single field with the value . Note: not recommended. If a new field is introduced at a later time, an older client updating with the may accidentally reset the new field's value. Not specifying any fields is an error.

.google.protobuf.FieldMask update_mask = 7 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
FieldMaskOrBuilder

hasCommonObjectRequestParams()

public boolean hasCommonObjectRequestParams()

A set of parameters common to Storage API requests concerning an object.

.google.storage.v2.CommonObjectRequestParams common_object_request_params = 8;

Returns
TypeDescription
boolean

Whether the commonObjectRequestParams field is set.

hasIfGenerationMatch()

public boolean hasIfGenerationMatch()

Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.

optional int64 if_generation_match = 2;

Returns
TypeDescription
boolean

Whether the ifGenerationMatch field is set.

hasIfGenerationNotMatch()

public boolean hasIfGenerationNotMatch()

Makes the operation conditional on whether the object's live generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.

optional int64 if_generation_not_match = 3;

Returns
TypeDescription
boolean

Whether the ifGenerationNotMatch field is set.

hasIfMetagenerationMatch()

public boolean hasIfMetagenerationMatch()

Makes the operation conditional on whether the object's current metageneration matches the given value.

optional int64 if_metageneration_match = 4;

Returns
TypeDescription
boolean

Whether the ifMetagenerationMatch field is set.

hasIfMetagenerationNotMatch()

public boolean hasIfMetagenerationNotMatch()

Makes the operation conditional on whether the object's current metageneration does not match the given value.

optional int64 if_metageneration_not_match = 5;

Returns
TypeDescription
boolean

Whether the ifMetagenerationNotMatch field is set.

hasObject()

public boolean hasObject()

Required. The object to update. The object's bucket and name fields are used to identify the object to update. If present, the object's generation field selects a specific revision of this object whose metadata should be updated. Otherwise, assumes the live version of the object.

.google.storage.v2.Object object = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
boolean

Whether the object field is set.

hasUpdateMask()

public boolean hasUpdateMask()

Required. List of fields to be updated. To specify ALL fields, equivalent to the JSON API's "update" function, specify a single field with the value . Note: not recommended. If a new field is introduced at a later time, an older client updating with the may accidentally reset the new field's value. Not specifying any fields is an error.

.google.protobuf.FieldMask update_mask = 7 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
boolean

Whether the updateMask field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeCommonObjectRequestParams(CommonObjectRequestParams value)

public UpdateObjectRequest.Builder mergeCommonObjectRequestParams(CommonObjectRequestParams value)

A set of parameters common to Storage API requests concerning an object.

.google.storage.v2.CommonObjectRequestParams common_object_request_params = 8;

Parameter
NameDescription
valueCommonObjectRequestParams
Returns
TypeDescription
UpdateObjectRequest.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public UpdateObjectRequest.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
UpdateObjectRequest.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public UpdateObjectRequest.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
UpdateObjectRequest.Builder
Overrides

mergeFrom(UpdateObjectRequest other)

public UpdateObjectRequest.Builder mergeFrom(UpdateObjectRequest other)
Parameter
NameDescription
otherUpdateObjectRequest
Returns
TypeDescription
UpdateObjectRequest.Builder

mergeObject(Object value)

public UpdateObjectRequest.Builder mergeObject(Object value)

Required. The object to update. The object's bucket and name fields are used to identify the object to update. If present, the object's generation field selects a specific revision of this object whose metadata should be updated. Otherwise, assumes the live version of the object.

.google.storage.v2.Object object = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueObject
Returns
TypeDescription
UpdateObjectRequest.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

public final UpdateObjectRequest.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
UpdateObjectRequest.Builder
Overrides

mergeUpdateMask(FieldMask value)

public UpdateObjectRequest.Builder mergeUpdateMask(FieldMask value)

Required. List of fields to be updated. To specify ALL fields, equivalent to the JSON API's "update" function, specify a single field with the value . Note: not recommended. If a new field is introduced at a later time, an older client updating with the may accidentally reset the new field's value. Not specifying any fields is an error.

.google.protobuf.FieldMask update_mask = 7 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueFieldMask
Returns
TypeDescription
UpdateObjectRequest.Builder

setCommonObjectRequestParams(CommonObjectRequestParams value)

public UpdateObjectRequest.Builder setCommonObjectRequestParams(CommonObjectRequestParams value)

A set of parameters common to Storage API requests concerning an object.

.google.storage.v2.CommonObjectRequestParams common_object_request_params = 8;

Parameter
NameDescription
valueCommonObjectRequestParams
Returns
TypeDescription
UpdateObjectRequest.Builder

setCommonObjectRequestParams(CommonObjectRequestParams.Builder builderForValue)

public UpdateObjectRequest.Builder setCommonObjectRequestParams(CommonObjectRequestParams.Builder builderForValue)

A set of parameters common to Storage API requests concerning an object.

.google.storage.v2.CommonObjectRequestParams common_object_request_params = 8;

Parameter
NameDescription
builderForValueCommonObjectRequestParams.Builder
Returns
TypeDescription
UpdateObjectRequest.Builder

setField(Descriptors.FieldDescriptor field, Object value)

public UpdateObjectRequest.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
UpdateObjectRequest.Builder
Overrides

setIfGenerationMatch(long value)

public UpdateObjectRequest.Builder setIfGenerationMatch(long value)

Makes the operation conditional on whether the object's current generation matches the given value. Setting to 0 makes the operation succeed only if there are no live versions of the object.

optional int64 if_generation_match = 2;

Parameter
NameDescription
valuelong

The ifGenerationMatch to set.

Returns
TypeDescription
UpdateObjectRequest.Builder

This builder for chaining.

setIfGenerationNotMatch(long value)

public UpdateObjectRequest.Builder setIfGenerationNotMatch(long value)

Makes the operation conditional on whether the object's live generation does not match the given value. If no live object exists, the precondition fails. Setting to 0 makes the operation succeed only if there is a live version of the object.

optional int64 if_generation_not_match = 3;

Parameter
NameDescription
valuelong

The ifGenerationNotMatch to set.

Returns
TypeDescription
UpdateObjectRequest.Builder

This builder for chaining.

setIfMetagenerationMatch(long value)

public UpdateObjectRequest.Builder setIfMetagenerationMatch(long value)

Makes the operation conditional on whether the object's current metageneration matches the given value.

optional int64 if_metageneration_match = 4;

Parameter
NameDescription
valuelong

The ifMetagenerationMatch to set.

Returns
TypeDescription
UpdateObjectRequest.Builder

This builder for chaining.

setIfMetagenerationNotMatch(long value)

public UpdateObjectRequest.Builder setIfMetagenerationNotMatch(long value)

Makes the operation conditional on whether the object's current metageneration does not match the given value.

optional int64 if_metageneration_not_match = 5;

Parameter
NameDescription
valuelong

The ifMetagenerationNotMatch to set.

Returns
TypeDescription
UpdateObjectRequest.Builder

This builder for chaining.

setObject(Object value)

public UpdateObjectRequest.Builder setObject(Object value)

Required. The object to update. The object's bucket and name fields are used to identify the object to update. If present, the object's generation field selects a specific revision of this object whose metadata should be updated. Otherwise, assumes the live version of the object.

.google.storage.v2.Object object = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueObject
Returns
TypeDescription
UpdateObjectRequest.Builder

setObject(Object.Builder builderForValue)

public UpdateObjectRequest.Builder setObject(Object.Builder builderForValue)

Required. The object to update. The object's bucket and name fields are used to identify the object to update. If present, the object's generation field selects a specific revision of this object whose metadata should be updated. Otherwise, assumes the live version of the object.

.google.storage.v2.Object object = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
builderForValueObject.Builder
Returns
TypeDescription
UpdateObjectRequest.Builder

setPredefinedAcl(String value)

public UpdateObjectRequest.Builder setPredefinedAcl(String value)

Apply a predefined set of access controls to this object. Valid values are "authenticatedRead", "bucketOwnerFullControl", "bucketOwnerRead", "private", "projectPrivate", or "publicRead".

string predefined_acl = 10;

Parameter
NameDescription
valueString

The predefinedAcl to set.

Returns
TypeDescription
UpdateObjectRequest.Builder

This builder for chaining.

setPredefinedAclBytes(ByteString value)

public UpdateObjectRequest.Builder setPredefinedAclBytes(ByteString value)

Apply a predefined set of access controls to this object. Valid values are "authenticatedRead", "bucketOwnerFullControl", "bucketOwnerRead", "private", "projectPrivate", or "publicRead".

string predefined_acl = 10;

Parameter
NameDescription
valueByteString

The bytes for predefinedAcl to set.

Returns
TypeDescription
UpdateObjectRequest.Builder

This builder for chaining.

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

public UpdateObjectRequest.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
UpdateObjectRequest.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final UpdateObjectRequest.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
UpdateObjectRequest.Builder
Overrides

setUpdateMask(FieldMask value)

public UpdateObjectRequest.Builder setUpdateMask(FieldMask value)

Required. List of fields to be updated. To specify ALL fields, equivalent to the JSON API's "update" function, specify a single field with the value . Note: not recommended. If a new field is introduced at a later time, an older client updating with the may accidentally reset the new field's value. Not specifying any fields is an error.

.google.protobuf.FieldMask update_mask = 7 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueFieldMask
Returns
TypeDescription
UpdateObjectRequest.Builder

setUpdateMask(FieldMask.Builder builderForValue)

public UpdateObjectRequest.Builder setUpdateMask(FieldMask.Builder builderForValue)

Required. List of fields to be updated. To specify ALL fields, equivalent to the JSON API's "update" function, specify a single field with the value . Note: not recommended. If a new field is introduced at a later time, an older client updating with the may accidentally reset the new field's value. Not specifying any fields is an error.

.google.protobuf.FieldMask update_mask = 7 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
builderForValueBuilder
Returns
TypeDescription
UpdateObjectRequest.Builder