class TransferBuffer
Defined at line 48 of file ../../src/storage/blobfs/transfer_buffer.h
TransferBuffer is an interface representing a transfer buffer which can be loaded with data from
the underlying storage device.
The VMO returned by |TransferBuffer::vmo()| is guaranteed to never be mapped by the instance,
which makes the VMO suitable for use with |zx_pager_supply_pages|.
Public Methods
zx::result<> Populate (uint64_t offset, uint64_t length, const LoaderInfo & info)
Loads the buffer with data from the inode corresponding to |info.identifier|, at the byte range
specified by [|offset|, |offset| + |length|).
|offset| must be block aligned. |length| may be rounded up to a block-aligned offset.
zx::result<> PopulateAndDecompress (const CompressionMapping & mapping, const LoaderInfo & info)
Same as above, but with driver decompression.
zx::vmo & GetVmo ()
Accesses the underlying VMO.
Must be preceded with a call to |TransferBuffer::Populate()|. The contents of the returned
VMO are only defined up to |length| bytes (the value passed to the last call to
|TransferBuffer::Populate()|).
size_t GetSize ()
Returns the size of the underlying VMO.
void ~TransferBuffer ()
Defined at line 50 of file ../../src/storage/blobfs/transfer_buffer.h