Class EnumArgument<T extends java.lang.Enum<T>>
- java.lang.Object
-
- net.minecraftforge.server.command.EnumArgument<T>
-
- All Implemented Interfaces:
com.mojang.brigadier.arguments.ArgumentType<T>
public class EnumArgument<T extends java.lang.Enum<T>> extends java.lang.Object implements com.mojang.brigadier.arguments.ArgumentType<T>
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
EnumArgument.Serializer
-
Field Summary
Fields Modifier and Type Field Description private java.lang.Class<T>
enumClass
private static com.mojang.brigadier.exceptions.Dynamic2CommandExceptionType
INVALID_ENUM
-
Constructor Summary
Constructors Modifier Constructor Description private
EnumArgument(java.lang.Class<T> enumClass)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static <R extends java.lang.Enum<R>>
EnumArgument<R>enumArgument(java.lang.Class<R> enumClass)
java.util.Collection<java.lang.String>
getExamples()
<S> java.util.concurrent.CompletableFuture<com.mojang.brigadier.suggestion.Suggestions>
listSuggestions(com.mojang.brigadier.context.CommandContext<S> context, com.mojang.brigadier.suggestion.SuggestionsBuilder builder)
T
parse(com.mojang.brigadier.StringReader reader)
-
-
-
Constructor Detail
-
EnumArgument
private EnumArgument(java.lang.Class<T> enumClass)
-
-
Method Detail
-
enumArgument
public static <R extends java.lang.Enum<R>> EnumArgument<R> enumArgument(java.lang.Class<R> enumClass)
-
parse
public T parse(com.mojang.brigadier.StringReader reader) throws com.mojang.brigadier.exceptions.CommandSyntaxException
-
listSuggestions
public <S> java.util.concurrent.CompletableFuture<com.mojang.brigadier.suggestion.Suggestions> listSuggestions(com.mojang.brigadier.context.CommandContext<S> context, com.mojang.brigadier.suggestion.SuggestionsBuilder builder)
-
-