Class NBTInputStream
java.lang.Object
com.github.imdabigboss.easydatapack.api.utils.nbt.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 http://www.minecraft.net/docs/NBT.txt.
- Author:
- Graham Edgecombe
-
Constructor Summary
ConstructorsConstructorDescriptionCreates 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.- Throws:
IOException- if an I/O error occurs.
-
-
Method Details
-
readTag
Reads an NBT tag from the stream.- Returns:
- The tag that was read.
- Throws:
IOException- if an I/O error occurs.
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-