Record Class ScriptBrigadierCommand
java.lang.Object
java.lang.Record
org.skriptlang.skript.bukkit.command.custom.ScriptBrigadierCommand
- Record Components:
script- The script this command is defined in.node- The command node providing functionality for this command.aliases- Aliases used to reference the command. Can be empty.description- String describing the command.namespace- An alternative namespace the command is registered under. If null, this command is registered under the default namespace (typicallyskript).
public record ScriptBrigadierCommand(Script script, com.mojang.brigadier.tree.LiteralCommandNode<io.papermc.paper.command.brigadier.CommandSourceStack> node, Collection<String> aliases, @Nullable String description, @Nullable String usage, @Nullable String namespace, @Nullable String permission)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionScriptBrigadierCommand(Script script, com.mojang.brigadier.tree.LiteralCommandNode<io.papermc.paper.command.brigadier.CommandSourceStack> node, Collection<String> aliases, @Nullable String description, @Nullable String usage, @Nullable String namespace, @Nullable String permission) Creates an instance of aScriptBrigadierCommandrecord class. -
Method Summary
Modifier and TypeMethodDescriptionaliases()Returns the value of thealiasesrecord component.@Nullable StringReturns the value of thedescriptionrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.@Nullable StringReturns the value of thenamespacerecord component.com.mojang.brigadier.tree.LiteralCommandNode<io.papermc.paper.command.brigadier.CommandSourceStack> node()Returns the value of thenoderecord component.@Nullable StringReturns the value of thepermissionrecord component.script()Returns the value of thescriptrecord component.final StringtoString()Returns a string representation of this record class.@Nullable Stringusage()Returns the value of theusagerecord component.
-
Constructor Details
-
ScriptBrigadierCommand
public ScriptBrigadierCommand(Script script, com.mojang.brigadier.tree.LiteralCommandNode<io.papermc.paper.command.brigadier.CommandSourceStack> node, Collection<String> aliases, @Nullable @Nullable String description, @Nullable @Nullable String usage, @Nullable @Nullable String namespace, @Nullable @Nullable String permission) Creates an instance of aScriptBrigadierCommandrecord class.- Parameters:
script- the value for thescriptrecord componentnode- the value for thenoderecord componentaliases- the value for thealiasesrecord componentdescription- the value for thedescriptionrecord componentusage- the value for theusagerecord componentnamespace- the value for thenamespacerecord componentpermission- the value for thepermissionrecord component
-
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
script
-
node
-
aliases
-
description
Returns the value of thedescriptionrecord component.- Returns:
- the value of the
descriptionrecord component
-
usage
Returns the value of theusagerecord component.- Returns:
- the value of the
usagerecord component
-
namespace
-
permission
Returns the value of thepermissionrecord component.- Returns:
- the value of the
permissionrecord component
-