Index
ByteStream
(interface)RestByteStream
(interface)Media
(message)UpdateMediaRequest
(message)WriteRequest
(message)WriteResponse
(message)
ByteStream
The Byte Stream API enables a client to read and write a stream of bytes to and from a resource. Resources have names, and these names are supplied in the API calls below to identify the resource that is being read from or written to.
All implementations of the Byte Stream API export the interface defined here:
Read()
: Reads the contents of a resource.Write()
: Writes the contents of a resource. The client can callWrite()
multiple times with the same resource and can check the status of the write by callingQueryWriteStatus()
.
The ByteStream API provides no direct way to access/modify any metadata associated with the resource.
The errors returned by the service are in the Google canonical error space.
Write | |
---|---|
A Calling When the client closes the request channel, the service will respond with a
|
RestByteStream
UpdateMedia | |
---|---|
Uploads media. Upload is supported on the URI
|
Media
Media resource.
Fields | |
---|---|
resource_name |
Name of the media resource. |
UpdateMediaRequest
Request message for uploading media.
Fields | |
---|---|
resource_name |
Name of the media that is being downloaded. See |
media |
Representation of the media that is being uploaded. |
WriteRequest
Request object for ByteStream.Write.
Fields | |
---|---|
resource_name |
The name of the resource to write. This must be set on the first |
write_offset |
The offset from the beginning of the resource at which the data should be written. It is required on all In the first On subsequent calls, this value must be set and must be equal to the sum of the first An incorrect value will cause an error. |
finish_write |
If |
data |
A portion of the data for the resource. The client may leave |
WriteResponse
Response object for ByteStream.Write
.
Fields | |
---|---|
committed_size |
The number of bytes that have been processed for the given resource. |