pub trait WriteableOnce: Sized {
    // Required method
    fn write_into<B: Writer + ?Sized>(self, b: &mut B) -> EncodeResult<()>;
}
Expand description

Trait for an object that can be encoded and consumed by a Writer.

Implement this trait in order to make an object that can be written more efficiently by absorbing it into the writer.

Most code won’t need to call this directly, but will instead use it implicitly via the Writer::write_and_consume() method.

Required Methods§

source

fn write_into<B: Writer + ?Sized>(self, b: &mut B) -> EncodeResult<()>

Encode this object into the writer b, and consume it.

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl<T: OutputSizeUser> WriteableOnce for CtOutput<T>

Implementors§