pub fn serialize<T>(data: &T) -> Vec<u8> ⓘwhere T: Encodable + ?Sized,
Encodes an object into a vector.