Expand description
§4.1 input format sniffing.
sniff_format peeks the first ~4 KiB of a BufRead without
consuming the content bytes (BOM bytes are consumed). The same
buffered reader is then handed to a parser, which sees the
still-pristine stream.
Structs§
- Sniff
Outcome - Outcome of
sniff_format.
Constants§
- SNIFF_
PROBE_ BYTES - Maximum prefix size used for sniffing, per §4.1 (“first ~4 KiB”).
Functions§
- sniff_
format - Peek the input and decide its format per §4.1.