Package net.minecraft.command.argument
Class ColorArgumentType
java.lang.Object
net.minecraft.command.argument.ColorArgumentType
- All Implemented Interfaces:
com.mojang.brigadier.arguments.ArgumentType<Formatting>
public class ColorArgumentType extends Object implements com.mojang.brigadier.arguments.ArgumentType<Formatting>
-
Field Summary
Fields Modifier and Type Field Description private static Collection<String>EXAMPLESstatic com.mojang.brigadier.exceptions.DynamicCommandExceptionTypeINVALID_COLOR_EXCEPTION -
Constructor Summary
Constructors Modifier Constructor Description privateColorArgumentType() -
Method Summary
Modifier and Type Method Description static ColorArgumentTypecolor()static FormattinggetColor(com.mojang.brigadier.context.CommandContext<ServerCommandSource> context, String name)Collection<String>getExamples()<S> CompletableFuture<com.mojang.brigadier.suggestion.Suggestions>listSuggestions(com.mojang.brigadier.context.CommandContext<S> context, com.mojang.brigadier.suggestion.SuggestionsBuilder builder)Formattingparse(com.mojang.brigadier.StringReader stringReader)
-
Field Details
-
EXAMPLES
-
INVALID_COLOR_EXCEPTION
public static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType INVALID_COLOR_EXCEPTION
-
-
Constructor Details
-
ColorArgumentType
private ColorArgumentType()
-
-
Method Details
-
color
-
getColor
public static Formatting getColor(com.mojang.brigadier.context.CommandContext<ServerCommandSource> context, String name) -
parse
public Formatting parse(com.mojang.brigadier.StringReader stringReader) throws com.mojang.brigadier.exceptions.CommandSyntaxException- Specified by:
parsein interfacecom.mojang.brigadier.arguments.ArgumentType<Formatting>- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
listSuggestions
public <S> CompletableFuture<com.mojang.brigadier.suggestion.Suggestions> listSuggestions(com.mojang.brigadier.context.CommandContext<S> context, com.mojang.brigadier.suggestion.SuggestionsBuilder builder)- Specified by:
listSuggestionsin interfacecom.mojang.brigadier.arguments.ArgumentType<Formatting>
-
getExamples
- Specified by:
getExamplesin interfacecom.mojang.brigadier.arguments.ArgumentType<Formatting>
-