pub fn encode_stream(stream: &ObsStream) -> StringExpand description
Serialize a canonical ObsStream back to CRINEX text (the inverse of
parse_stream).
CRINEX compression is not unique, so this emits the canonical all-reset
form: every observation and the receiver clock are written as 1&value
arc-init tokens (no higher-order differencing) and every epoch descriptor is
written as a text-diff reset. Only the per-satellite LLI/SSI flag strings are
genuinely text-differenced, because the flag grammar has no inline reset
marker. The result is therefore not byte-identical to an arbitrary source
CRINEX, but it is a valid CRINEX stream that decodes to exactly the same plain
RINEX text. The round-trip guarantee is decode(encode_stream(parse_stream(x))) == decode(x) and parse_stream(encode_stream(s)) == s.