Trait bonsaidb::core::ordered_varint::Variable[]

pub trait Variable {
    fn encode_variable<W>(&self, destination: &mut W) -> Result<usize, Error>
    where
        W: Write
;
fn decode_variable<R>(source: R) -> Result<Self, Error>
    where
        R: Read
; fn to_variable_vec(&self) -> Result<Vec<u8, Global>, Error> { ... } }
Expand description

Encodes and decodes a type using a variable-length format.

Required methods

Encodes self into destination, returning the number of bytes written upon success.

Decodes a variable length value from source.

Provided methods

Encodes self into a new Vec<u8>.

Implementations on Foreign Types

Implementors