Class ArgumentColor
java.lang.Object
net.minestom.server.command.builder.arguments.Argument<Style>
net.minestom.server.command.builder.arguments.minecraft.ArgumentColor
Represents an argument which will give you a
Style containing the colour or no
colour if the argument was reset.
Example: red, white, reset
-
Field Summary
FieldsFields inherited from class net.minestom.server.command.builder.arguments.Argument
allowSpace, CONTAINER, suggestionType, useRemaining -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription@NotNull Styleparse(@NotNull CommandSender sender, @NotNull String input) Parses the given input, and throw anArgumentSyntaxExceptionif the input cannot be converted toTparser()toString()Methods inherited from class net.minestom.server.command.builder.arguments.Argument
allowSpace, equals, filter, getCallback, getDefaultValue, getId, getSuggestionCallback, hasErrorCallback, hashCode, hasSuggestion, isOptional, map, map, nodeProperties, parse, setCallback, setDefaultValue, setDefaultValue, setDefaultValue, setSuggestionCallback, suggestionType, useRemaining
-
Field Details
-
UNDEFINED_COLOR
public static final int UNDEFINED_COLOR- See Also:
-
-
Constructor Details
-
ArgumentColor
-
-
Method Details
-
parse
@NotNull public @NotNull Style parse(@NotNull @NotNull CommandSender sender, @NotNull @NotNull String input) throws ArgumentSyntaxException Description copied from class:ArgumentParses the given input, and throw anArgumentSyntaxExceptionif the input cannot be converted toT- Specified by:
parsein classArgument<Style>- Parameters:
input- the argument to parse- Returns:
- the parsed argument
- Throws:
ArgumentSyntaxException- ifvalueis not valid
-
parser
-
toString
-