pub fn decode(
buf: &[u8],
) -> Result<Option<(OwnedFrame, usize)>, RedisProtocolError>
Available on crate feature
resp3
only.Expand description
Attempt to decode the contents of buf
, returning the first valid frame and the number of bytes consumed.
If the buffer contains an incomplete frame then None
is returned.