from_slice_split_tail

Function from_slice_split_tail 

Source
pub fn from_slice_split_tail<'a, T>(input: &'a [u8]) -> Result<(T, &'a [u8])>
where T: Deserialize<'a>,
Expand description

Deserialize an instance of type T from a slice of bytes in a MessagePack format.

Return a tuple with (value, tail), where tail is the tail of the input beginning at the byte following the last byte of the serialized data.

Any &str or &[u8] in the returned type will contain references to the provided slice.