pub fn encode_tag<T: Serialize>(o: &T) -> Result<Option<Tag>, NBTError>Expand description
Encode a Serde serializable value into a NBT Tag.
ยงExample
use nbt::{encode_tag, Tag};
let list: Vec<i8> = vec![127, 42, 10];
let tag = encode_tag(&list).unwrap().unwrap();