Class HopperInventorySearchEvent

java.lang.Object
org.bukkit.event.Event
org.bukkit.event.block.BlockEvent
org.bukkit.event.inventory.HopperInventorySearchEvent

public class HopperInventorySearchEvent extends BlockEvent
Event that gets called each time a Hopper attempts to find its source/attached containers.
  • Constructor Details

  • Method Details

    • setInventory

      public void setInventory(@Nullable Inventory inventory)
      Set the Inventory that the Hopper will use for its source/attached Container.
      Parameters:
      inventory - the inventory to use
    • getInventory

      @Nullable public Inventory getInventory()
      Gets the Inventory that the Hopper will use for its source/attached Container.
      Returns:
      the inventory which will be used
    • getContainerType

      @NotNull public HopperInventorySearchEvent.ContainerType getContainerType()
      Gets the Container type the Hopper is searching for.
      Returns:
      the container type being searched for
    • getSearchBlock

      @NotNull public Block getSearchBlock()
      Gets the Block that is being searched for an inventory.
      Returns:
      block being searched for an inventory
    • getHandlers

      @NotNull public HandlerList getHandlers()
      Specified by:
      getHandlers in class Event
    • getHandlerList

      @NotNull public static HandlerList getHandlerList()