SerenityJS
    Preparing search index...

    Class ItemTypeComponentCollection

    Hierarchy

    • CompoundTag<unknown>
      • ItemTypeComponentCollection
    Index

    Constructors

    Properties

    entries: Map<string, ItemTypeComponent> = ...

    The component definitions of the item type.

    item: ItemType

    The type of item that the components are for.

    name: string

    The name of the tag.

    type: TagType

    The nbt tag type of the data type.

    value: unknown

    The value of the tag.

    type: Compound = TagType.Compound

    The nbt tag type of the data type.

    Methods

    • Parameters

      • tag: Tag

      Returns void

    • Parameters

      • properties: Partial<TagProperties<number>>

      Returns ByteTag

    • Type Parameters

      • T

      Parameters

      • properties: Partial<TagProperties<T>>

      Returns CompoundTag<T>

    • Parameters

      • properties: Partial<TagProperties<number>>

      Returns DoubleTag

    • Parameters

      • properties: Partial<TagProperties<number>>

      Returns FloatTag

    • Parameters

      • properties: Partial<TagProperties<number>>

      Returns IntTag

    • Type Parameters

      • T extends Tag<unknown>

      Parameters

      • properties: Partial<TagProperties<T[]>> & { listType: TagType }

      Returns ListTag<T>

    • Parameters

      • properties: Partial<TagProperties<bigint>>

      Returns LongTag

    • Parameters

      • properties: Partial<TagProperties<number>>

      Returns ShortTag

    • Parameters

      • properties: Partial<TagProperties<string>>

      Returns StringTag

    • Type Parameters

      • K extends Tag<unknown>

      Parameters

      • name: string

      Returns K

    • Returns Tag<unknown>[]

    • Parameters

      • name: string

      Returns boolean

    • Parameters

      • name: string

      Returns void

    • Parameters

      • name: string
      • tag: Tag

      Returns void

    • Returns TagProperties<unknown> & { type: TagType }

    • Type Parameters

      • T

      Parameters

      • buffer: Buffer
      • Optionalvarint: boolean

      Returns CompoundTag<T>

    • Read a nbt tag from a binary stream.

      Type Parameters

      • T

      Parameters

      • stream: BinaryStream

        The binary stream to read from.

      • Optionalvarint: boolean

        Whether to read the tag as a varint.

      • Optionalproperties: Partial<ReadingProperties>

      Returns CompoundTag<T>

    • Parameters

      • stream: BinaryStream
      • Optionalvarint: boolean

      Returns string

    • Write a nbt tag to a binary stream.

      Type Parameters

      • T

      Parameters

      • stream: BinaryStream

        The binary stream to write to.

      • value: CompoundTag<T>

        The value of the tag.

      • Optionalvarint: boolean

        Whether to write the tag as a varint.

      • Optionalproperties: Partial<WritingProperties>

      Returns void

    • Parameters

      • value: string
      • stream: BinaryStream
      • Optionalvarint: boolean

      Returns void