Trait dusk_bytes::Write

source ·
pub trait Write {
    // Required method
    fn write(&mut self, buf: &[u8]) -> Result<usize, Error>;
}
Expand description

Implementors of the Write trait are sometimes called ‘writers’.

Writers are defined by one required method, [write()].

Required Methods§

source

fn write(&mut self, buf: &[u8]) -> Result<usize, Error>

Write a buffer into this writer, returning how many bytes were written.

This function will attempt to write the entire contents of buf, but the entire write may not succeed, or the write may also generate an error.

Implementations on Foreign Types§

source§

impl Write for &mut [u8]

source§

fn write(&mut self, buf: &[u8]) -> Result<usize, Error>

Implementors§