Record Class BukkitEventUpdateEvent
java.lang.Object
java.lang.Record
kr.toxicity.hud.api.bukkit.update.BukkitEventUpdateEvent
- Record Components:
event- original eventkey- event's key
- All Implemented Interfaces:
kr.toxicity.hud.api.update.UpdateEvent
public record BukkitEventUpdateEvent(@NotNull org.bukkit.event.Event event, @NotNull Object key)
extends Record
implements kr.toxicity.hud.api.update.UpdateEvent
Represents wrapped event of bukkit
-
Field Summary
Fields inherited from interface kr.toxicity.hud.api.update.UpdateEvent
EMPTY -
Constructor Summary
ConstructorsConstructorDescriptionBukkitEventUpdateEvent(@NotNull org.bukkit.event.Event event, @NotNull Object key) Creates an instance of aBukkitEventUpdateEventrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.@NotNull org.bukkit.event.Eventevent()Returns the value of theeventrecord component.@NotNull ObjectgetKey()@NotNull kr.toxicity.hud.api.update.UpdateReasongetType()final inthashCode()Returns a hash code value for this object.@NotNull Objectkey()Returns the value of thekeyrecord component.final StringtoString()Returns a string representation of this record class.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface kr.toxicity.hud.api.update.UpdateEvent
source
-
Constructor Details
-
Method Details
-
getType
@NotNull public @NotNull kr.toxicity.hud.api.update.UpdateReason getType()- Specified by:
getTypein interfacekr.toxicity.hud.api.update.UpdateEvent
-
getKey
- Specified by:
getKeyin interfacekr.toxicity.hud.api.update.UpdateEvent
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
event
@NotNull public @NotNull org.bukkit.event.Event event()Returns the value of theeventrecord component.- Returns:
- the value of the
eventrecord component
-
key
Returns the value of thekeyrecord component.- Returns:
- the value of the
keyrecord component
-