pub fn to_binary_writer<W: Write>(
    writer: W,
    compound: &Compound,
    root_name: &str
) -> Result<(), Error>
Expand description

Encodes uncompressed NBT binary data to the provided writer.

Only compounds are permitted at the top level. This is why the function accepts a Compound reference rather than a Value.

Additionally, the root compound can be given a name. Typically the empty string "" is used.