pub fn to_writer<T, W>(writer: W, value: &T) -> Result<(), Error>where W: Write, T: BorshSerialize + ?Sized,
Serializes an object directly into a Writer.
Writer