Class WriteObjectRequest (2.50.0)

publicfinalclassWriteObjectRequestextendsGeneratedMessageV3implementsWriteObjectRequestOrBuilder

Request message for WriteObject.

Protobuf type google.storage.v2.WriteObjectRequest

Static Fields

CHECKSUMMED_DATA_FIELD_NUMBER

publicstaticfinalintCHECKSUMMED_DATA_FIELD_NUMBER
Field Value
TypeDescription
int

COMMON_OBJECT_REQUEST_PARAMS_FIELD_NUMBER

publicstaticfinalintCOMMON_OBJECT_REQUEST_PARAMS_FIELD_NUMBER
Field Value
TypeDescription
int

FINISH_WRITE_FIELD_NUMBER

publicstaticfinalintFINISH_WRITE_FIELD_NUMBER
Field Value
TypeDescription
int

OBJECT_CHECKSUMS_FIELD_NUMBER

publicstaticfinalintOBJECT_CHECKSUMS_FIELD_NUMBER
Field Value
TypeDescription
int

UPLOAD_ID_FIELD_NUMBER

publicstaticfinalintUPLOAD_ID_FIELD_NUMBER
Field Value
TypeDescription
int

WRITE_OBJECT_SPEC_FIELD_NUMBER

publicstaticfinalintWRITE_OBJECT_SPEC_FIELD_NUMBER
Field Value
TypeDescription
int

WRITE_OFFSET_FIELD_NUMBER

publicstaticfinalintWRITE_OFFSET_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

publicstaticWriteObjectRequestgetDefaultInstance()
Returns
TypeDescription
WriteObjectRequest

getDescriptor()

publicstaticfinalDescriptors.DescriptorgetDescriptor()
Returns
TypeDescription
Descriptor

newBuilder()

publicstaticWriteObjectRequest.BuildernewBuilder()
Returns
TypeDescription
WriteObjectRequest.Builder

newBuilder(WriteObjectRequest prototype)

publicstaticWriteObjectRequest.BuildernewBuilder(WriteObjectRequestprototype)
Parameter
NameDescription
prototypeWriteObjectRequest
Returns
TypeDescription
WriteObjectRequest.Builder

parseDelimitedFrom(InputStream input)

publicstaticWriteObjectRequestparseDelimitedFrom(InputStreaminput)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
WriteObjectRequest
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

publicstaticWriteObjectRequestparseDelimitedFrom(InputStreaminput,ExtensionRegistryLiteextensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
WriteObjectRequest
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

publicstaticWriteObjectRequestparseFrom(byte[]data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
WriteObjectRequest
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

publicstaticWriteObjectRequestparseFrom(byte[]data,ExtensionRegistryLiteextensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
WriteObjectRequest
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

publicstaticWriteObjectRequestparseFrom(ByteStringdata)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
WriteObjectRequest
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

publicstaticWriteObjectRequestparseFrom(ByteStringdata,ExtensionRegistryLiteextensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
WriteObjectRequest
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

publicstaticWriteObjectRequestparseFrom(CodedInputStreaminput)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
WriteObjectRequest
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

publicstaticWriteObjectRequestparseFrom(CodedInputStreaminput,ExtensionRegistryLiteextensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
WriteObjectRequest
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

publicstaticWriteObjectRequestparseFrom(InputStreaminput)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
WriteObjectRequest
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

publicstaticWriteObjectRequestparseFrom(InputStreaminput,ExtensionRegistryLiteextensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
WriteObjectRequest
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

publicstaticWriteObjectRequestparseFrom(ByteBufferdata)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
WriteObjectRequest
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

publicstaticWriteObjectRequestparseFrom(ByteBufferdata,ExtensionRegistryLiteextensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
WriteObjectRequest
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

publicstaticParser<WriteObjectRequest>parser()
Returns
TypeDescription
Parser<WriteObjectRequest>

Methods

equals(Object obj)

publicbooleanequals(Objectobj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getChecksummedData()

publicChecksummedDatagetChecksummedData()

The data to insert. If a crc32c checksum is provided that doesn't match the checksum computed by the service, the request will fail.

.google.storage.v2.ChecksummedData checksummed_data = 4;

Returns
TypeDescription
ChecksummedData

The checksummedData.

getChecksummedDataOrBuilder()

publicChecksummedDataOrBuildergetChecksummedDataOrBuilder()

The data to insert. If a crc32c checksum is provided that doesn't match the checksum computed by the service, the request will fail.

.google.storage.v2.ChecksummedData checksummed_data = 4;

Returns
TypeDescription
ChecksummedDataOrBuilder

getCommonObjectRequestParams()

publicCommonObjectRequestParamsgetCommonObjectRequestParams()

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.

getCommonObjectRequestParamsOrBuilder()

publicCommonObjectRequestParamsOrBuildergetCommonObjectRequestParamsOrBuilder()

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

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

Returns
TypeDescription
CommonObjectRequestParamsOrBuilder

getDataCase()

publicWriteObjectRequest.DataCasegetDataCase()
Returns
TypeDescription
WriteObjectRequest.DataCase

getDefaultInstanceForType()

publicWriteObjectRequestgetDefaultInstanceForType()
Returns
TypeDescription
WriteObjectRequest

getFinishWrite()

publicbooleangetFinishWrite()

If true, this indicates that the write is complete. Sending any WriteObjectRequests subsequent to one in which finish_write is true will cause an error. For a non-resumable write (where the upload_id was not set in the first message), it is an error not to set this field in the final message of the stream.

bool finish_write = 7;

Returns
TypeDescription
boolean

The finishWrite.

getFirstMessageCase()

publicWriteObjectRequest.FirstMessageCasegetFirstMessageCase()
Returns
TypeDescription
WriteObjectRequest.FirstMessageCase

getObjectChecksums()

publicObjectChecksumsgetObjectChecksums()

Checksums for the complete object. If the checksums computed by the service don't match the specified checksums the call will fail. May only be provided in the first or last request (either with first_message, or finish_write set).

.google.storage.v2.ObjectChecksums object_checksums = 6;

Returns
TypeDescription
ObjectChecksums

The objectChecksums.

getObjectChecksumsOrBuilder()

publicObjectChecksumsOrBuildergetObjectChecksumsOrBuilder()

Checksums for the complete object. If the checksums computed by the service don't match the specified checksums the call will fail. May only be provided in the first or last request (either with first_message, or finish_write set).

.google.storage.v2.ObjectChecksums object_checksums = 6;

Returns
TypeDescription
ObjectChecksumsOrBuilder

getParserForType()

publicParser<WriteObjectRequest>getParserForType()
Returns
TypeDescription
Parser<WriteObjectRequest>
Overrides

getSerializedSize()

publicintgetSerializedSize()
Returns
TypeDescription
int
Overrides

getUploadId()

publicStringgetUploadId()

For resumable uploads. This should be the upload_id returned from a call to StartResumableWriteResponse.

string upload_id = 1;

Returns
TypeDescription
String

The uploadId.

getUploadIdBytes()

publicByteStringgetUploadIdBytes()

For resumable uploads. This should be the upload_id returned from a call to StartResumableWriteResponse.

string upload_id = 1;

Returns
TypeDescription
ByteString

The bytes for uploadId.

getWriteObjectSpec()

publicWriteObjectSpecgetWriteObjectSpec()

For non-resumable uploads. Describes the overall upload, including the destination bucket and object name, preconditions, etc.

.google.storage.v2.WriteObjectSpec write_object_spec = 2;

Returns
TypeDescription
WriteObjectSpec

The writeObjectSpec.

getWriteObjectSpecOrBuilder()

publicWriteObjectSpecOrBuildergetWriteObjectSpecOrBuilder()

For non-resumable uploads. Describes the overall upload, including the destination bucket and object name, preconditions, etc.

.google.storage.v2.WriteObjectSpec write_object_spec = 2;

Returns
TypeDescription
WriteObjectSpecOrBuilder

getWriteOffset()

publiclonggetWriteOffset()

Required. The offset from the beginning of the object at which the data should be written.

In the first WriteObjectRequest of a WriteObject() action, it indicates the initial offset for the Write() call. The value must be equal to the persisted_size that a call to QueryWriteStatus() would return (0 if this is the first write to the object).

On subsequent calls, this value must be no larger than the sum of the first write_offset and the sizes of all data chunks sent previously on this stream.

An incorrect value will cause an error.

int64 write_offset = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
long

The writeOffset.

hasChecksummedData()

publicbooleanhasChecksummedData()

The data to insert. If a crc32c checksum is provided that doesn't match the checksum computed by the service, the request will fail.

.google.storage.v2.ChecksummedData checksummed_data = 4;

Returns
TypeDescription
boolean

Whether the checksummedData field is set.

hasCommonObjectRequestParams()

publicbooleanhasCommonObjectRequestParams()

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.

hasObjectChecksums()

publicbooleanhasObjectChecksums()

Checksums for the complete object. If the checksums computed by the service don't match the specified checksums the call will fail. May only be provided in the first or last request (either with first_message, or finish_write set).

.google.storage.v2.ObjectChecksums object_checksums = 6;

Returns
TypeDescription
boolean

Whether the objectChecksums field is set.

hasUploadId()

publicbooleanhasUploadId()

For resumable uploads. This should be the upload_id returned from a call to StartResumableWriteResponse.

string upload_id = 1;

Returns
TypeDescription
boolean

Whether the uploadId field is set.

hasWriteObjectSpec()

publicbooleanhasWriteObjectSpec()

For non-resumable uploads. Describes the overall upload, including the destination bucket and object name, preconditions, etc.

.google.storage.v2.WriteObjectSpec write_object_spec = 2;

Returns
TypeDescription
boolean

Whether the writeObjectSpec field is set.

hashCode()

publicinthashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protectedGeneratedMessageV3.FieldAccessorTableinternalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

publicfinalbooleanisInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

publicWriteObjectRequest.BuildernewBuilderForType()
Returns
TypeDescription
WriteObjectRequest.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protectedWriteObjectRequest.BuildernewBuilderForType(GeneratedMessageV3.BuilderParentparent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
WriteObjectRequest.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protectedObjectnewInstance(GeneratedMessageV3.UnusedPrivateParameterunused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

publicWriteObjectRequest.BuildertoBuilder()
Returns
TypeDescription
WriteObjectRequest.Builder

writeTo(CodedOutputStream output)

publicvoidwriteTo(CodedOutputStreamoutput)
Parameter
NameDescription
outputCodedOutputStream
Overrides
Exceptions
TypeDescription
IOException