Interface ItemComparator<T>

Type Parameters:
T - the type of the item
All Known Subinterfaces:
ItemMetaComparator
All Known Implementing Classes:
AmountModifier, DurabilityModifier, EnchantmentModifier, ItemFlagModifier, LoreModifier, MaterialModifier, NameModifier, PotionEffectModifier, SkullModifier

public interface ItemComparator<T>
An extension to ItemModifier to compare the modifier of an item
  • Method Summary

    Modifier and Type
    Method
    Description
    default boolean
    compare(T item)
    Compare the modifier of an item
    default boolean
    compare(T item, @Nullable UUID uuid)
    Compare the modifier of an item
    boolean
    compare(T item, @Nullable UUID uuid, StringReplacer stringReplacer)
    Compare the modifier of an item
  • Method Details

    • compare

      boolean compare(@NotNull T item, @Nullable @Nullable UUID uuid, StringReplacer stringReplacer)
      Compare the modifier of an item
      Parameters:
      item - the item
      uuid - the unique id
      stringReplacer - the string replacer
      Returns:
      true if it matches, otherwise false
    • compare

      default boolean compare(@NotNull T item, @Nullable @Nullable UUID uuid)
      Compare the modifier of an item
      Parameters:
      item - the item
      uuid - the unique id
      Returns:
      true if it matches, otherwise false
    • compare

      default boolean compare(@NotNull T item)
      Compare the modifier of an item
      Parameters:
      item - the item
      Returns:
      true if it matches, otherwise false