pub enum BlobWriterRequest {
GetVmo {
size: u64,
responder: BlobWriterGetVmoResponder,
},
BytesReady {
bytes_written: u64,
responder: BlobWriterBytesReadyResponder,
},
}
Variants§
GetVmo
Truncates the blob associated with this BlobWriter proxy to length size
. Returns a handle
to a vmo
shared between the server and the client, which is implemented as a ring buffer.
As the client writes blob contents into the vmo
, it will call BytesReady to signal to the
server that some number of bytes have been written.
Ring Buffer Semantics The server sets the size of the vmo passed back to the client. The chunks that the client writes are arbitrarily sized and do not have any alignment guarantees. Any particular write can wrap around the ring buffer. The client can have several outstanding BytesReady requests but the client is responsible for not overwriting a given range in the ring buffer until the BytesReady request corresponding to that range has completed.
BytesReady
Indicates to the server that an additional bytes_written
number of bytes have been
written to the shared vmo and are ready to be read off the vmo and written to disk. The
blob will be readable when the final BytesReady response is received by the client.
Implementations§
Source§impl BlobWriterRequest
impl BlobWriterRequest
pub fn into_get_vmo(self) -> Option<(u64, BlobWriterGetVmoResponder)>
pub fn into_bytes_ready(self) -> Option<(u64, BlobWriterBytesReadyResponder)>
Sourcepub fn method_name(&self) -> &'static str
pub fn method_name(&self) -> &'static str
Name of the method defined in FIDL