pub fn to_bytes<T: Serialize>(data_item: &T) -> Vec<u8>
Examples found in repository?
src/serialization.rs (line 1094)
1090
1091
1092
1093
1094
1095
1096
1097
    fn serialize<'a, W: Write + Sized>(
        &self,
        serializer: &'a mut Serializer<W>,
    ) -> cbor_event::Result<&'a mut Serializer<W>> {
        let bytes = to_bytes(&self.0);
        serializer.write_tag(24)?.write_bytes(&bytes)?;
        Ok(serializer)
    }