Package net.kyori.adventure.nbt
Interface BinaryTagIO.Writer
-
- Enclosing class:
- BinaryTagIO
public static interface BinaryTagIO.Writer
CompoundBinaryTag
writer.- Since:
- 4.4.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description void
write(@NonNull CompoundBinaryTag tag, @NonNull DataOutput output)
Writes a binary tag tooutput
.default void
write(@NonNull CompoundBinaryTag tag, @NonNull OutputStream output)
Writes a binary tag tooutput
.void
write(@NonNull CompoundBinaryTag tag, @NonNull OutputStream output, @NonNull BinaryTagIO.Compression compression)
Writes a binary tag tooutput
with acompression
type.default void
write(@NonNull CompoundBinaryTag tag, @NonNull Path path)
Writes a binary tag topath
with acompression
type.void
write(@NonNull CompoundBinaryTag tag, @NonNull Path path, @NonNull BinaryTagIO.Compression compression)
Writes a binary tag topath
with acompression
type.void
writeNamed(@NonNull Map.Entry<String,CompoundBinaryTag> tag, @NonNull DataOutput output)
Writes a binary tag, with a name, tooutput
.default void
writeNamed(@NonNull Map.Entry<String,CompoundBinaryTag> tag, @NonNull OutputStream output)
Writes a binary tag, with a name, tooutput
.void
writeNamed(@NonNull Map.Entry<String,CompoundBinaryTag> tag, @NonNull OutputStream output, @NonNull BinaryTagIO.Compression compression)
Writes a binary tag, with a name, tooutput
with acompression
type.default void
writeNamed(@NonNull Map.Entry<String,CompoundBinaryTag> tag, @NonNull Path path)
Writes a binary tag, with a name, topath
.void
writeNamed(@NonNull Map.Entry<String,CompoundBinaryTag> tag, @NonNull Path path, @NonNull BinaryTagIO.Compression compression)
Writes a binary tag, with a name, topath
with acompression
type.
-
-
-
Method Detail
-
write
default void write(@NonNull CompoundBinaryTag tag, @NonNull Path path) throws IOException
Writes a binary tag topath
with acompression
type.This is the equivalent of passing
Compression#NONE
as the second parameter towrite(CompoundBinaryTag, Path, Compression)
.- Parameters:
path
- the path- Throws:
IOException
- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
write
void write(@NonNull CompoundBinaryTag tag, @NonNull Path path, @NonNull BinaryTagIO.Compression compression) throws IOException
Writes a binary tag topath
with acompression
type.- Parameters:
path
- the pathcompression
- the compression type- Throws:
IOException
- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
write
default void write(@NonNull CompoundBinaryTag tag, @NonNull OutputStream output) throws IOException
Writes a binary tag tooutput
.This is the equivalent of passing
BinaryTagIO.Compression.NONE
as the second parameter towrite(CompoundBinaryTag, OutputStream, Compression)
.- Parameters:
output
- the output stream- Throws:
IOException
- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
write
void write(@NonNull CompoundBinaryTag tag, @NonNull OutputStream output, @NonNull BinaryTagIO.Compression compression) throws IOException
Writes a binary tag tooutput
with acompression
type.- Parameters:
output
- the output streamcompression
- the compression type- Throws:
IOException
- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
write
void write(@NonNull CompoundBinaryTag tag, @NonNull DataOutput output) throws IOException
Writes a binary tag tooutput
.- Parameters:
output
- the output- Throws:
IOException
- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
writeNamed
default void writeNamed(@NonNull Map.Entry<String,CompoundBinaryTag> tag, @NonNull Path path) throws IOException
Writes a binary tag, with a name, topath
.This is the equivalent of passing
Compression#NONE
as the second parameter towrite(CompoundBinaryTag, Path, Compression)
.- Parameters:
path
- the path- Throws:
IOException
- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
writeNamed
void writeNamed(@NonNull Map.Entry<String,CompoundBinaryTag> tag, @NonNull Path path, @NonNull BinaryTagIO.Compression compression) throws IOException
Writes a binary tag, with a name, topath
with acompression
type.- Parameters:
path
- the pathcompression
- the compression type- Throws:
IOException
- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
writeNamed
default void writeNamed(@NonNull Map.Entry<String,CompoundBinaryTag> tag, @NonNull OutputStream output) throws IOException
Writes a binary tag, with a name, tooutput
.This is the equivalent of passing
Compression#NONE
as the second parameter towrite(CompoundBinaryTag, OutputStream, Compression)
.- Parameters:
output
- the output stream- Throws:
IOException
- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
writeNamed
void writeNamed(@NonNull Map.Entry<String,CompoundBinaryTag> tag, @NonNull OutputStream output, @NonNull BinaryTagIO.Compression compression) throws IOException
Writes a binary tag, with a name, tooutput
with acompression
type.- Parameters:
output
- the output streamcompression
- the compression type- Throws:
IOException
- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
writeNamed
void writeNamed(@NonNull Map.Entry<String,CompoundBinaryTag> tag, @NonNull DataOutput output) throws IOException
Writes a binary tag, with a name, tooutput
.- Parameters:
output
- the output- Throws:
IOException
- if an exception was encountered while reading the tag- Since:
- 4.4.0
-
-