Trait sparse::Writer

source ·
pub trait Writer: Write + Seek {
    // Required method
    fn set_len(&mut self, size: u64) -> Result<()>;
}
Expand description

A union trait for Write and Seek that also allows truncation.

Required Methods§

source

fn set_len(&mut self, size: u64) -> Result<()>

Sets the length of the output stream.

Implementations on Foreign Types§

source§

impl Writer for File

source§

fn set_len(&mut self, size: u64) -> Result<()>

source§

impl Writer for Cursor<Vec<u8>>

source§

fn set_len(&mut self, size: u64) -> Result<()>

Implementors§