Class InventoryHolderContainsMatcher

java.lang.Object
org.hamcrest.BaseMatcher<InventoryHolder>
org.hamcrest.TypeSafeMatcher<InventoryHolder>
org.mockbukkit.mockbukkit.matcher.inventory.holder.InventoryHolderContainsMatcher
All Implemented Interfaces:
org.hamcrest.Matcher<InventoryHolder>, org.hamcrest.SelfDescribing

public class InventoryHolderContainsMatcher extends org.hamcrest.TypeSafeMatcher<InventoryHolder>
  • Constructor Details

    • InventoryHolderContainsMatcher

      public InventoryHolderContainsMatcher(ItemStack itemStack)
  • Method Details

    • matchesSafely

      protected boolean matchesSafely(InventoryHolder inventoryHolder)
      Specified by:
      matchesSafely in class org.hamcrest.TypeSafeMatcher<InventoryHolder>
    • describeTo

      public void describeTo(org.hamcrest.Description description)
    • describeMismatchSafely

      protected void describeMismatchSafely(InventoryHolder inventoryHolder, @NotNull @NotNull org.hamcrest.Description mismatchDescription)
      Overrides:
      describeMismatchSafely in class org.hamcrest.TypeSafeMatcher<InventoryHolder>
    • hasItemInInventory

      @NotNull public static @NotNull InventoryHolderContainsMatcher hasItemInInventory(@NotNull @NotNull ItemStack itemStack)
      Parameters:
      itemStack - The item stack required for there to be a match
      Returns:
      A matcher which matches with any inventory of specified item stack
    • doesNotHaveItemInInventory

      @NotNull public static @NotNull org.hamcrest.Matcher<InventoryHolder> doesNotHaveItemInInventory(@NotNull @NotNull ItemStack itemStack)
      Parameters:
      itemStack - The item stack required for there to be no match
      Returns:
      A matcher which matches with any inventory without the specified item stack