Struct websocket::ws::util::mask::Masker [] [src]

pub struct Masker<'w, W> where W: Write + 'w {
    // some fields omitted
}

Struct to pipe data into another writer, while masking the data being written

Methods

impl<'w, W> Masker<'w, W> where W: Write + 'w

fn new(key: [u8; 4], endpoint: &'w mut W) -> Self

Create a new Masker with the key and the endpoint to be writter to.

Trait Implementations

impl<'w, W> Write for Masker<'w, W> where W: Write + 'w

fn write(&mut self, data: &[u8]) -> IoResult<usize>

fn flush(&mut self) -> IoResult<()>

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

1.0.0fn write_fmt(&mut self, fmt: Arguments) -> Result<(), Error>

1.0.0fn by_ref(&mut self) -> &mut Self