Skip to main content

Writer

Trait Writer 

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

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

Required Methods§

Source

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

Sets the length of the output stream.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl Writer for Cursor<Vec<u8>>

Source§

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

Source§

impl Writer for File

Source§

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

Implementors§