[−][src]Module destream::de
Stream deserialization framework based on serde::de
.
The two most important traits in this module are FromStream
and Decoder
.
- A type that implements
FromStream
is a data structure that can be decoded from any stream encoding supported bydestream
, and conversely - A type that implements
Decoder
is a data format that can decode any supported stream.
The FromStream trait
destream
implements FromStream
for many Rust primitive and standard library types.
The complete list is below.
Implementations of FromStream provided by destream
- Primitive types:
- ()
- bool
- i8, i16, i32, i64
- u8, u16, u32, u64
- f32, f64
- Compound types:
- [T; 0] through [T; 32]
- tuples up to size 16
- Common standard library types:
- String
- Option<T>
- PhantomData<T>
- Collection types:
- BTreeMap<K, V>
- BTreeSet<T>
- BinaryHeap<T>
- HashMap<K, V, H>
- HashSet<T, H>
- LinkedList<T>
- VecDeque<T>
- Vec<T>
Traits
Decoder | A data format that can decode a given well-formatted stream using one or more |
Error | The |
Expected |
|
FromStream | This trait describes a value which can be decoded from a stream. |
MapAccess | Provides a |
SeqAccess | Provides a |
Visitor | This trait describes a visitor responsible for decoding a stream. |