Package com.sk89q.jnbt
Class NBTInputStream
java.lang.Object
com.sk89q.jnbt.NBTInputStream
- All Implemented Interfaces:
Closeable
,AutoCloseable
This class reads NBT, or Named Binary Tag
streams, and produces an object graph of subclasses of the
Tag
object.
The NBT format was created by Markus Persson, and the specification may be found at https://minecraft.gamepedia.com/NBT_format.
-
Constructor Summary
ConstructorDescriptionCreates a newNBTInputStream
, which will source its data from the specified input stream. -
Method Summary
-
Constructor Details
-
NBTInputStream
Creates a newNBTInputStream
, which will source its data from the specified input stream.- Parameters:
is
- the input stream
-
-
Method Details
-
readNamedTag
Reads an NBT tag from the stream.- Returns:
- The tag that was read.
- Throws:
IOException
- if an I/O error occurs.
-
close
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Throws:
IOException
-