Package net.minecraft.commands.arguments
Class StringRepresentableArgument<T extends Enum<T> & StringRepresentable>
java.lang.Object
net.minecraft.commands.arguments.StringRepresentableArgument<T>
- All Implemented Interfaces:
com.mojang.brigadier.arguments.ArgumentType<T>
- Direct Known Subclasses:
TemplateMirrorArgument
,TemplateRotationArgument
public class StringRepresentableArgument<T extends Enum<T> & StringRepresentable>
extends Object
implements com.mojang.brigadier.arguments.ArgumentType<T>
-
Field Summary
-
Constructor Summary
ModifierConstructorDescriptionprotected
StringRepresentableArgument
(com.mojang.serialization.Codec<T> p_234060_, Supplier<T[]> p_234061_) -
Method Summary
Modifier and TypeMethodDescription<S> CompletableFuture<com.mojang.brigadier.suggestion.Suggestions>
listSuggestions
(com.mojang.brigadier.context.CommandContext<S> p_234074_, com.mojang.brigadier.suggestion.SuggestionsBuilder p_234075_) parse
(com.mojang.brigadier.StringReader p_234063_)
-
Field Details
-
ERROR_INVALID_VALUE
private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType ERROR_INVALID_VALUE -
codec
-
values
-
-
Constructor Details
-
StringRepresentableArgument
-
-
Method Details
-
parse
public T parse(com.mojang.brigadier.StringReader p_234063_) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Specified by:
parse
in interfacecom.mojang.brigadier.arguments.ArgumentType<T extends Enum<T> & StringRepresentable>
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
listSuggestions
public <S> CompletableFuture<com.mojang.brigadier.suggestion.Suggestions> listSuggestions(com.mojang.brigadier.context.CommandContext<S> p_234074_, com.mojang.brigadier.suggestion.SuggestionsBuilder p_234075_) - Specified by:
listSuggestions
in interfacecom.mojang.brigadier.arguments.ArgumentType<T extends Enum<T> & StringRepresentable>
-
getExamples
- Specified by:
getExamples
in interfacecom.mojang.brigadier.arguments.ArgumentType<T extends Enum<T> & StringRepresentable>
-