Class SerializedItemStackPlainNBT
java.lang.Object
sawfowl.localeapi.api.serializetools.itemstack.SerializedItemStackPlainNBT
- All Implemented Interfaces:
CompoundTag
The class is intended for working with item data when it is necessary to access it before registering item data in the registry.
-
Constructor Summary
ConstructorsConstructorDescriptionSerializedItemStackPlainNBT
(String type, int quantity, String nbt) SerializedItemStackPlainNBT
(ItemStack itemStack) -
Method Summary
Modifier and TypeMethodDescriptionboolean
boolean
equalsToItemStack
(ItemStack itemStack) boolean
equalsWhithoutNBT
(SerializedItemStackPlainNBT itemStack) boolean
net.kyori.adventure.key.Key
The resulting value can be used to display the item in chat.GettingItemStack
GettingItemType
getNBT()
Get all tags as a string.Gaining access to the NBT tags of an item.GettingItemStack
volume.int
hashCode()
void
setQuantity
(int quantity) ChangingItemStack
volume.com.google.gson.JsonObject
Convert class objects to json data array.
It is recommended not to do `return null`.toString()
-
Constructor Details
-
SerializedItemStackPlainNBT
-
SerializedItemStackPlainNBT
-
SerializedItemStackPlainNBT
-
SerializedItemStackPlainNBT
-
-
Method Details
-
getItemTypeAsString
-
getQuantity
GettingItemStack
volume. -
getNBT
Get all tags as a string. -
getItemStack
GettingItemStack
-
getItemType
GettingItemType
-
getItemKey
public net.kyori.adventure.key.Key getItemKey()The resulting value can be used to display the item in chat. -
getOrCreateTag
Gaining access to the NBT tags of an item. -
setQuantity
public void setQuantity(int quantity) ChangingItemStack
volume. -
toSerializedItemStackJsonNbt
-
hashCode
public int hashCode() -
equals
-
equalsWhithoutQuantity
-
equalsWhithoutNBT
-
equalsToItemStack
-
toString
-
toJsonObject
public com.google.gson.JsonObject toJsonObject()Description copied from interface:CompoundTag
Convert class objects to json data array.
It is recommended not to do `return null`.- Specified by:
toJsonObject
in interfaceCompoundTag
-