pub fn deserialize<'de, D, const N: usize>(
deserializer: D,
) -> Result<[u8; N], D::Error>where
D: Deserializer<'de>,Available on crate feature
serde only.Expand description
Deserializes exactly N bytes into an owned array.
Empty payloads succeed only for N == 0.
§Errors
Checks any required prefix, even payload length, exact decoded length, then characters/case. Length errors count decoded bytes; invalid-byte positions exclude the prefix. Format errors propagate.
§Examples
See the module example.