pub struct LargeValueWriter { /* private fields */ }Expand description
Writer for chunked large values.
Implementations§
Source§impl LargeValueWriter
impl LargeValueWriter
Sourcepub fn create(path: &Path, meta: LargeValueMeta) -> Result<Self>
pub fn create(path: &Path, meta: LargeValueMeta) -> Result<Self>
Creates a new chunked writer at the given path.
Sourcepub fn meta(&self) -> LargeValueMeta
pub fn meta(&self) -> LargeValueMeta
Returns the metadata describing this large value.
Sourcepub fn remaining(&self) -> u64
pub fn remaining(&self) -> u64
Returns remaining bytes expected before the writer reaches total_len.
Sourcepub fn chunk_size(&self) -> u32
pub fn chunk_size(&self) -> u32
Maximum chunk size permitted for this writer.
Sourcepub fn write_chunk(&mut self, chunk: &[u8]) -> Result<()>
pub fn write_chunk(&mut self, chunk: &[u8]) -> Result<()>
Writes a single chunk. Chunks must respect the configured chunk_size and total_len.
Auto Trait Implementations§
impl Freeze for LargeValueWriter
impl RefUnwindSafe for LargeValueWriter
impl Send for LargeValueWriter
impl Sync for LargeValueWriter
impl Unpin for LargeValueWriter
impl UnsafeUnpin for LargeValueWriter
impl UnwindSafe for LargeValueWriter
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more