Record Class MachineAction.Click
java.lang.Object
java.lang.Record
fr.robie.machineengine.api.machine.MachineAction.Click
- Record Components:
player- who clickedindex- the button's index (index:; the row of aMachineList), 0 by defaultheld- the stack on the cursor, or the stack shift-clicked forMachineAction.ClickKind.INSERT; null if none
- Enclosing interface:
MachineAction
public static record MachineAction.Click(@NotNull UUID player, @NotNull MachineAction.ClickKind kind, int index, @Nullable ResourceStack held)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionClick(@NotNull UUID player, @NotNull MachineAction.ClickKind kind, int index, @Nullable ResourceStack held) Creates an instance of aClickrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.@Nullable ResourceStackheld()Returns the value of theheldrecord component.intindex()Returns the value of theindexrecord component.@NotNull MachineAction.ClickKindkind()Returns the value of thekindrecord component.@NotNull UUIDplayer()Returns the value of theplayerrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Click
public Click(@NotNull @NotNull UUID player, @NotNull @NotNull MachineAction.ClickKind kind, int index, @Nullable @Nullable ResourceStack held) Creates an instance of aClickrecord class.
-
-
Method Details
-
toString
-
hashCode
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
player
-
kind
Returns the value of thekindrecord component.- Returns:
- the value of the
kindrecord component
-
index
-
held
-