Crate read_from

Source
Expand description

The ReadFrom and WriteTo traits.

These traits allow you to represent the ability of a type to be serialized/ deserialized into an arbitrary byte stream. Because there’s no universal way to represent integers (outside of u8 and i8), endian types are provided to explicitly denote the endianness when deserializing.

§Serde

This is not the same as serde! Serde is used to serialize/deserialize types regardless of the data format. The ReadFrom/ WriteTo traits are intended to be used at a lower-level, where details such as the ordering of bytes is important.

Structs§

  • A type that can be used to deserialize integers in big-endian format.
  • A type that can be used to read/write integers in a little-endian format.
  • A type that can be used to deserialize integers in native-endian format.

Traits§

  • Used to deserialize types from an input stream (i.e. a Read implementation).
  • Used to serialize types into an output stream (i.e. a Write implementation).

Type Aliases§