Trait benko::encode::EncodeBencode[][src]

pub trait EncodeBencode<T: ParseBenc<T>> {
    fn bytes(&self) -> Vec<u8>;
}

Any type that implements the ParseBenc can also by design be converted back into a bencoded byte array.

Required methods

fn bytes(&self) -> Vec<u8>[src]

Parses the Bencode typed object back into a bencoded array of bytes.

This function won’t fail. If a type implements ParseBenc it will have come from bencode already.

Loading content...

Implementors

Loading content...