java.lang.Object
org.geysermc.mcprotocollib.protocol.data.game.entity.metadata.ItemStack

public class ItemStack extends Object
  • Constructor Details

    • ItemStack

      public ItemStack(int id, int amount, @Nullable com.viaversion.nbt.mini.MNBT nbt)
    • ItemStack

      public ItemStack(int id)
    • ItemStack

      public ItemStack(int id, int amount)
  • Method Details

    • getId

      public int getId()
    • getAmount

      public int getAmount()
    • getNbt

      public @Nullable com.viaversion.nbt.mini.MNBT getNbt()
    • setAmount

      public void setAmount(int amount)
    • toString

      public @NonNull String toString()
      Overrides:
      toString in class Object
    • equals

      public boolean equals(@Nullable Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(@Nullable Object other)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • getEnchantments

      public it.unimi.dsi.fastutil.objects.Object2IntMap<EnchantmentType> getEnchantments()
    • getCompoundTag

      public com.viaversion.nbt.tag.CompoundTag getCompoundTag()