Expand description
Unified layer under development, for now rssn only provide campatible version choises.
Modules§
- config
- The config module is used to change the behavior of bincode’s encoding and decoding logic.
- de
- Decoder-based structs and traits.
- enc
- Encoder-based structs and traits.
- error
- Errors that can be encounting by Encoding and Decoding.
- serde
- Support for serde integration. Enable this with the
serdefeature.
Macros§
- impl_
borrow_ decode - Helper macro to implement
BorrowDecodefor any type that implementsDecode. - impl_
borrow_ decode_ with_ context - Helper macro to implement
BorrowDecodefor any type that implementsDecode.
Traits§
- Borrow
Decode - Trait that makes a type able to be decoded, akin to serde’s
Deserializetrait. - Decode
- Trait that makes a type able to be decoded, akin to serde’s
DeserializeOwnedtrait. - Encode
- Any source that can be encoded. This trait should be implemented for all types that you want to be able to use with any of the
encode_withmethods.
Functions§
- borrow_
decode_ from_ slice - Attempt to decode a given type
Dfrom the given slice. Returns the decoded output and the amount of bytes read. - borrow_
decode_ from_ slice_ with_ context - Attempt to decode a given type
Dfrom the given slice withContext. Returns the decoded output and the amount of bytes read. - decode_
from_ reader - Attempt to decode a given type
Dfrom the given Reader. - decode_
from_ slice - Attempt to decode a given type
Dfrom the given slice. Returns the decoded output and the amount of bytes read. - decode_
from_ slice_ with_ context - Attempt to decode a given type
Dfrom the given slice withContext. Returns the decoded output and the amount of bytes read. - decode_
from_ std_ read - Decode type
Dfrom the given reader with the givenConfig. The reader can be any type that implementsstd::io::Read, e.g.std::fs::File. - decode_
from_ std_ read_ with_ context - Decode type
Dfrom the given reader with the givenConfigandContext. The reader can be any type that implementsstd::io::Read, e.g.std::fs::File. - encode_
into_ slice - Encode the given value into the given slice. Returns the amount of bytes that have been written.
- encode_
into_ std_ write - Encode the given value into any type that implements
std::io::Write, e.g.std::fs::File, with the givenConfig. See the config module for more information. Returns the amount of bytes written. - encode_
into_ writer - Encode the given value into a custom Writer.
- encode_
to_ vec - Encode the given value into a
Vec<u8>with the givenConfig. See the config module for more information.