pub fn deserialize_buffer<T: Deserialize>( contents: &[u8]) -> Result<T, T::Error>
Deserialize deserializable type from buffer.