Record Class DialogAction.RunCommand
java.lang.Object
java.lang.Record
org.geysermc.geyser.session.dialog.action.DialogAction.RunCommand
- All Implemented Interfaces:
DialogAction,DialogAction.CommandAction
- Enclosing interface:
- DialogAction
public static record DialogAction.RunCommand(String command)
extends Record
implements DialogAction.CommandAction
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.geysermc.geyser.session.dialog.action.DialogAction
DialogAction.CommandAction, DialogAction.Custom, DialogAction.DynamicCustom, DialogAction.DynamicRunCommand, DialogAction.OpenUrl, DialogAction.RunCommand, DialogAction.ShowDialog -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionRunCommand(String command) Creates an instance of aRunCommandrecord class. -
Method Summary
Modifier and TypeMethodDescriptioncommand()Returns the value of thecommandrecord component.command(GeyserSession session, ParsedInputs inputs) final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.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 org.geysermc.geyser.session.dialog.action.DialogAction.CommandAction
run, trimmedCommand
-
Field Details
-
TYPE
public static final net.kyori.adventure.key.Key TYPE
-
-
Constructor Details
-
RunCommand
Creates an instance of aRunCommandrecord class.- Parameters:
command- the value for thecommandrecord component
-
-
Method Details
-
command
- Specified by:
commandin interfaceDialogAction.CommandAction
-
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). -
command
Returns the value of thecommandrecord component.- Returns:
- the value of the
commandrecord component
-