Portability | portable |
---|---|
Stability | experimental |
Maintainer | acfoltzer@gmail.com |
Safe Haskell | None |
Defines a Haskell representation of Minecraft's NBT binary data
format, along with instances of Serialize
. See the
NBT specification for details:
https://raw.github.com/acfoltzer/nbt/master/NBT-spec.txt.
- data TagType
- = EndType
- | ByteType
- | ShortType
- | IntType
- | LongType
- | FloatType
- | DoubleType
- | ByteArrayType
- | StringType
- | ListType
- | CompoundType
- | IntArrayType
- data NBT = NBT Text NbtContents
- data NbtContents
- getByType :: TagType -> Get NbtContents
- getArrayElements :: (IArray arr a, Integral len, Ix len) => len -> Get a -> Get (arr len a)
- putContents :: NbtContents -> Put
- typeOf :: NbtContents -> TagType
Documentation
Tag types listed in order so that deriving Enum
will assign
them the correct number for the binary type field.
Primitive representation of NBT data. This type contains only the data part, since named nodes can only exist inside compound nodes.
data NbtContents Source
getByType :: TagType -> Get NbtContentsSource
putContents :: NbtContents -> PutSource
typeOf :: NbtContents -> TagTypeSource