blob: d6f43b26295e5afc12149942210965697e4eaa76 [file] [log] [blame] [raw]
package net.querz.nbt.io;
import net.querz.nbt.tag.Tag;
import java.io.IOException;
public class SNBTUtil {
public static String toSNBT(Tag<?> tag) throws IOException {
return new SNBTSerializer().toString(tag);
}
public static Tag<?> fromSNBT(String string) throws IOException {
return new SNBTDeserializer().fromString(string);
}
public static Tag<?> fromSNBT(String string, boolean lenient) throws IOException {
return new SNBTParser(string).parse(Tag.DEFAULT_MAX_DEPTH, lenient);
}
}