Class HoverEvent.ShowItem

java.lang.Object
net.kyori.adventure.text.event.HoverEvent.ShowItem
All Implemented Interfaces:
net.kyori.examination.Examinable
Enclosing class:
HoverEvent<V>

public static final class HoverEvent.ShowItem
extends Object
implements net.kyori.examination.Examinable
The value of a show_item hover event.
Since:
4.0.0
  • Method Details

    • of

      public static @NonNull HoverEvent.ShowItem of​(@NonNull Key item, @org.checkerframework.checker.index.qual.NonNegative int count)
      Creates.
      Parameters:
      item - the item
      count - the count
      Returns:
      a ShowItem
      Since:
      4.0.0
    • of

      public static @NonNull HoverEvent.ShowItem of​(@NonNull Key item, @org.checkerframework.checker.index.qual.NonNegative int count, @Nullable BinaryTagHolder nbt)
      Creates.
      Parameters:
      item - the item
      count - the count
      nbt - the nbt
      Returns:
      a ShowItem
      Since:
      4.0.0
    • item

      public @NonNull Key item()
      Gets the item.
      Returns:
      the item
      Since:
      4.0.0
    • item

      public @NonNull HoverEvent.ShowItem item​(@NonNull Key item)
      Sets the item.
      Parameters:
      item - the item
      Returns:
      a ShowItem
      Since:
      4.0.0
    • count

      public @org.checkerframework.checker.index.qual.NonNegative int count()
      Gets the count.
      Returns:
      the count
      Since:
      4.0.0
    • count

      public @NonNull HoverEvent.ShowItem count​(@org.checkerframework.checker.index.qual.NonNegative int count)
      Sets the count.
      Parameters:
      count - the count
      Returns:
      a ShowItem
      Since:
      4.0.0
    • nbt

      public @Nullable BinaryTagHolder nbt()
      Gets the nbt.
      Returns:
      the nbt
      Since:
      4.0.0
    • nbt

      public @NonNull HoverEvent.ShowItem nbt​(@Nullable BinaryTagHolder nbt)
      Sets the nbt.
      Parameters:
      nbt - the nbt
      Returns:
      a ShowItem
      Since:
      4.0.0
    • equals

      public boolean equals​(@Nullable Object other)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • examinableProperties

      public @NonNull Stream<? extends net.kyori.examination.ExaminableProperty> examinableProperties()
      Specified by:
      examinableProperties in interface net.kyori.examination.Examinable
    • toString

      public String toString()
      Overrides:
      toString in class Object