pub trait StacksMessageCodec {
    fn consensus_serialize<W: Write>(&self, fd: &mut W) -> Result<(), Error>
    where
        Self: Sized
; fn consensus_deserialize<R: Read>(fd: &mut R) -> Result<Self, Error>
    where
        Self: Sized
; fn serialize_to_vec(&self) -> Vec<u8>Notable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
    A: Allocator,

    where
        Self: Sized
, { ... } }
Expand description

Helper trait for various primitive types that make up Stacks messages

Required Methods

serialize implementors should never error unless there is an underlying failure in writing to the fd

Provided Methods

Convenience for serialization to a vec. this function unwraps any underlying serialization error

Implementations on Foreign Types

Implementors