[][src]Trait elrond_codec::NestedEncodeOutput

pub trait NestedEncodeOutput {
    pub fn write(&mut self, bytes: &[u8]);

    pub fn push_byte(&mut self, byte: u8) { ... }
}

Trait that allows appending bytes. Used especially by the NestedEncode trait to output data.

In principle it can be anything, but in practice we only keep 1 implementation, which is Vec. This is to avoid code duplication by monomorphization.

Required methods

pub fn write(&mut self, bytes: &[u8])[src]

Write to the output.

Loading content...

Provided methods

pub fn push_byte(&mut self, byte: u8)[src]

Write a single byte to the output.

Loading content...

Implementors

impl NestedEncodeOutput for Vec<u8>[src]

Loading content...