Package net.kyori.adventure.nbt
Interface BinaryTagIO.Writer
-
- Enclosing class:
- BinaryTagIO
public static interface BinaryTagIO.WriterCompoundBinaryTagwriter.- Since:
- 4.4.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description voidwrite(@NotNull CompoundBinaryTag tag, @NotNull java.io.DataOutput output)Writes a binary tag tooutput.default voidwrite(@NotNull CompoundBinaryTag tag, @NotNull java.io.OutputStream output)Writes a binary tag tooutput.voidwrite(@NotNull CompoundBinaryTag tag, @NotNull java.io.OutputStream output, @NotNull BinaryTagIO.Compression compression)Writes a binary tag tooutputwith acompressiontype.default voidwrite(@NotNull CompoundBinaryTag tag, @NotNull java.nio.file.Path path)Writes a binary tag topathwith acompressiontype.voidwrite(@NotNull CompoundBinaryTag tag, @NotNull java.nio.file.Path path, @NotNull BinaryTagIO.Compression compression)Writes a binary tag topathwith acompressiontype.voidwriteNamed(@NotNull java.util.Map.Entry<java.lang.String,CompoundBinaryTag> tag, @NotNull java.io.DataOutput output)Writes a binary tag, with a name, tooutput.default voidwriteNamed(@NotNull java.util.Map.Entry<java.lang.String,CompoundBinaryTag> tag, @NotNull java.io.OutputStream output)Writes a binary tag, with a name, tooutput.voidwriteNamed(@NotNull java.util.Map.Entry<java.lang.String,CompoundBinaryTag> tag, @NotNull java.io.OutputStream output, @NotNull BinaryTagIO.Compression compression)Writes a binary tag, with a name, tooutputwith acompressiontype.default voidwriteNamed(@NotNull java.util.Map.Entry<java.lang.String,CompoundBinaryTag> tag, @NotNull java.nio.file.Path path)Writes a binary tag, with a name, topath.voidwriteNamed(@NotNull java.util.Map.Entry<java.lang.String,CompoundBinaryTag> tag, @NotNull java.nio.file.Path path, @NotNull BinaryTagIO.Compression compression)Writes a binary tag, with a name, topathwith acompressiontype.
-
-
-
Method Detail
-
write
default void write(@NotNull @NotNull CompoundBinaryTag tag, @NotNull @NotNull java.nio.file.Path path) throws java.io.IOExceptionWrites a binary tag topathwith acompressiontype.This is the equivalent of passing
Compression#NONEas the second parameter towrite(CompoundBinaryTag, Path, Compression).- Parameters:
tag- the tag to writepath- the path- Throws:
java.io.IOException- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
write
void write(@NotNull @NotNull CompoundBinaryTag tag, @NotNull @NotNull java.nio.file.Path path, @NotNull @NotNull BinaryTagIO.Compression compression) throws java.io.IOExceptionWrites a binary tag topathwith acompressiontype.- Parameters:
tag- the tag to writepath- the pathcompression- the compression type- Throws:
java.io.IOException- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
write
default void write(@NotNull @NotNull CompoundBinaryTag tag, @NotNull @NotNull java.io.OutputStream output) throws java.io.IOExceptionWrites a binary tag tooutput.This is the equivalent of passing
BinaryTagIO.Compression.NONEas the second parameter towrite(CompoundBinaryTag, OutputStream, Compression).- Parameters:
tag- the tag to writeoutput- the output stream- Throws:
java.io.IOException- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
write
void write(@NotNull @NotNull CompoundBinaryTag tag, @NotNull @NotNull java.io.OutputStream output, @NotNull @NotNull BinaryTagIO.Compression compression) throws java.io.IOExceptionWrites a binary tag tooutputwith acompressiontype.- Parameters:
tag- the tag to writeoutput- the output streamcompression- the compression type- Throws:
java.io.IOException- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
write
void write(@NotNull @NotNull CompoundBinaryTag tag, @NotNull @NotNull java.io.DataOutput output) throws java.io.IOExceptionWrites a binary tag tooutput.- Parameters:
tag- the tag to writeoutput- the output- Throws:
java.io.IOException- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
writeNamed
default void writeNamed(@NotNull java.util.Map.Entry<java.lang.String,CompoundBinaryTag> tag, @NotNull @NotNull java.nio.file.Path path) throws java.io.IOException
Writes a binary tag, with a name, topath.This is the equivalent of passing
Compression#NONEas the second parameter towrite(CompoundBinaryTag, Path, Compression).- Parameters:
tag- the named tag entry to writepath- the path- Throws:
java.io.IOException- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
writeNamed
void writeNamed(@NotNull java.util.Map.Entry<java.lang.String,CompoundBinaryTag> tag, @NotNull @NotNull java.nio.file.Path path, @NotNull @NotNull BinaryTagIO.Compression compression) throws java.io.IOException
Writes a binary tag, with a name, topathwith acompressiontype.- Parameters:
tag- the named tag entry to writepath- the pathcompression- the compression type- Throws:
java.io.IOException- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
writeNamed
default void writeNamed(@NotNull java.util.Map.Entry<java.lang.String,CompoundBinaryTag> tag, @NotNull @NotNull java.io.OutputStream output) throws java.io.IOException
Writes a binary tag, with a name, tooutput.This is the equivalent of passing
Compression#NONEas the second parameter towrite(CompoundBinaryTag, OutputStream, Compression).- Parameters:
tag- the named tag entry to writeoutput- the output stream- Throws:
java.io.IOException- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
writeNamed
void writeNamed(@NotNull java.util.Map.Entry<java.lang.String,CompoundBinaryTag> tag, @NotNull @NotNull java.io.OutputStream output, @NotNull @NotNull BinaryTagIO.Compression compression) throws java.io.IOException
Writes a binary tag, with a name, tooutputwith acompressiontype.- Parameters:
tag- the named tag entry to writeoutput- the output streamcompression- the compression type- Throws:
java.io.IOException- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
writeNamed
void writeNamed(@NotNull java.util.Map.Entry<java.lang.String,CompoundBinaryTag> tag, @NotNull @NotNull java.io.DataOutput output) throws java.io.IOException
Writes a binary tag, with a name, tooutput.- Parameters:
tag- the named tag entry to writeoutput- the output- Throws:
java.io.IOException- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
-