Trait dialectic_tokio_serde::Deserializer [−][src]
The deserialization end of a serialization format: an object which can deserialize to any
non-lifetime-restricted Deserialize
value.
This trait resembles serde::Deserializer
, but is not identical
to it. Unlike serde::Deserializer
, it is parameterized by the
Input
to a deserializer, which might be something like Bytes
, String
, or another input
format.
Most serde::Deserializer
s can be easily given an instance of
Deserializer
. When implementing this trait, you should usually be as general as possible for
the Input
parameter. Consider whether you can implement it for all AsRef<[u8]>
or
AsRef<str>
rather than a single concrete input format.
Associated Types
Loading content...Required methods
fn deserialize<T: for<'a> Deserialize<'a>>(
&mut self,
src: &Input
) -> Result<T, Self::Error>
[src]
&mut self,
src: &Input
) -> Result<T, Self::Error>
Deserialize any Deserialize
value from the input format (e.g. Bytes
, String
, etc.),
provided that the deserialized value can live forever.