Class HopperMock

All Implemented Interfaces:
com.destroystokyo.paper.loottable.LootableBlockInventory, com.destroystokyo.paper.loottable.LootableInventory, org.bukkit.block.BlockState, org.bukkit.block.Container, org.bukkit.block.Hopper, org.bukkit.block.Lockable, org.bukkit.block.TileState, org.bukkit.inventory.BlockInventoryHolder, org.bukkit.inventory.InventoryHolder, org.bukkit.loot.Lootable, org.bukkit.metadata.Metadatable, org.bukkit.Nameable, org.bukkit.persistence.PersistentDataHolder

public class HopperMock extends ContainerMock implements org.bukkit.block.Hopper
This ContainerMock represents a Hopper.
  • Constructor Details

    • HopperMock

      public HopperMock(@NotNull @NotNull org.bukkit.Material material)
    • HopperMock

      protected HopperMock(@NotNull @NotNull org.bukkit.block.Block block)
    • HopperMock

      protected HopperMock(@NotNull @NotNull HopperMock state)
  • Method Details

    • setLootTable

      public void setLootTable(org.bukkit.loot.LootTable table)
      Specified by:
      setLootTable in interface org.bukkit.loot.Lootable
    • getLootTable

      public org.bukkit.loot.LootTable getLootTable()
      Specified by:
      getLootTable in interface org.bukkit.loot.Lootable
    • setSeed

      public void setSeed(long seed)
      Specified by:
      setSeed in interface org.bukkit.loot.Lootable
    • getSeed

      public long getSeed()
      Specified by:
      getSeed in interface org.bukkit.loot.Lootable
    • createInventory

      protected InventoryMock createInventory()
      Specified by:
      createInventory in class ContainerMock
    • getSnapshot

      @NotNull public @NotNull org.bukkit.block.BlockState getSnapshot()
      Description copied from class: BlockStateMock
      This returns a copy of this BlockStateMock. Inheritents of this class should override this method!
      Specified by:
      getSnapshot in class ContainerMock
      Returns:
      A snapshot of this BlockStateMock.
    • isRefillEnabled

      public boolean isRefillEnabled()
      Specified by:
      isRefillEnabled in interface com.destroystokyo.paper.loottable.LootableInventory
    • hasBeenFilled

      public boolean hasBeenFilled()
      Specified by:
      hasBeenFilled in interface com.destroystokyo.paper.loottable.LootableInventory
    • hasPlayerLooted

      public boolean hasPlayerLooted(@NotNull @NotNull UUID player)
      Specified by:
      hasPlayerLooted in interface com.destroystokyo.paper.loottable.LootableInventory
    • getLastLooted

      @Nullable public @Nullable Long getLastLooted(@NotNull @NotNull UUID player)
      Specified by:
      getLastLooted in interface com.destroystokyo.paper.loottable.LootableInventory
    • setHasPlayerLooted

      public boolean setHasPlayerLooted(@NotNull @NotNull UUID player, boolean looted)
      Specified by:
      setHasPlayerLooted in interface com.destroystokyo.paper.loottable.LootableInventory
    • hasPendingRefill

      public boolean hasPendingRefill()
      Specified by:
      hasPendingRefill in interface com.destroystokyo.paper.loottable.LootableInventory
    • getLastFilled

      public long getLastFilled()
      Specified by:
      getLastFilled in interface com.destroystokyo.paper.loottable.LootableInventory
    • getNextRefill

      public long getNextRefill()
      Specified by:
      getNextRefill in interface com.destroystokyo.paper.loottable.LootableInventory
    • setNextRefill

      public long setNextRefill(long refillAt)
      Specified by:
      setNextRefill in interface com.destroystokyo.paper.loottable.LootableInventory