Interface ContainerSingleItem

All Superinterfaces:
Clearable, Container
All Known Subinterfaces:
ContainerSingleItem.BlockContainerSingleItem
All Known Implementing Classes:
DecoratedPotBlockEntity, JukeboxBlockEntity

public interface ContainerSingleItem extends Container
  • Method Details

    • getTheItem

      ItemStack getTheItem()
    • splitTheItem

      default ItemStack splitTheItem(int pAmount)
    • setTheItem

      void setTheItem(ItemStack pItem)
    • removeTheItem

      default ItemStack removeTheItem()
    • getContainerSize

      default int getContainerSize()
      Specified by:
      getContainerSize in interface Container
    • isEmpty

      default boolean isEmpty()
      Specified by:
      isEmpty in interface Container
    • clearContent

      default void clearContent()
      Specified by:
      clearContent in interface Clearable
    • removeItemNoUpdate

      default ItemStack removeItemNoUpdate(int pSlot)
      Removes a stack from the given slot and returns it.
      Specified by:
      removeItemNoUpdate in interface Container
    • getItem

      default ItemStack getItem(int pSlot)
      Returns the stack in the given slot.
      Specified by:
      getItem in interface Container
    • removeItem

      default ItemStack removeItem(int pSlot, int pAmount)
      Removes up to a specified number of items from an inventory slot and returns them in a new stack.
      Specified by:
      removeItem in interface Container
    • setItem

      default void setItem(int pSlot, ItemStack pStack)
      Sets the given item stack to the specified slot in the inventory (can be crafting or armor sections).
      Specified by:
      setItem in interface Container