pub fn encode_timestamp(
buf: &mut BytesMut,
tag_number: u8,
ts: &BACnetTimeStamp,
) -> Result<(), Error>Expand description
Encode a BACnetTimeStamp wrapped in a context opening/closing tag pair.
Delegates to encode_timestamp_to_sink through the growable buffer,
retaining the existing result type.
The outer tag_number is the context tag of the enclosing field.
Inside, the CHOICE variant uses its own context tag (0=Time,
1=SequenceNumber, 2=DateTime) via encode_timestamp_choice.