Package net.minecraft.command.argument
Class TimeArgumentType
java.lang.Object
net.minecraft.command.argument.TimeArgumentType
- All Implemented Interfaces:
com.mojang.brigadier.arguments.ArgumentType<Integer>
public class TimeArgumentType extends Object implements com.mojang.brigadier.arguments.ArgumentType<Integer>
-
Field Summary
Fields Modifier and Type Field Description private static Collection<String>
EXAMPLES
private static com.mojang.brigadier.exceptions.DynamicCommandExceptionType
INVALID_COUNT_EXCEPTION
private static com.mojang.brigadier.exceptions.SimpleCommandExceptionType
INVALID_UNIT_EXCEPTION
private static Object2IntMap<String>
UNITS
-
Constructor Summary
Constructors Constructor Description TimeArgumentType()
-
Method Summary
Modifier and Type Method Description Collection<String>
getExamples()
<S> CompletableFuture<com.mojang.brigadier.suggestion.Suggestions>
listSuggestions(com.mojang.brigadier.context.CommandContext<S> context, com.mojang.brigadier.suggestion.SuggestionsBuilder builder)
Integer
parse(com.mojang.brigadier.StringReader stringReader)
static TimeArgumentType
time()
-
Field Details
-
EXAMPLES
-
INVALID_UNIT_EXCEPTION
private static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType INVALID_UNIT_EXCEPTION -
INVALID_COUNT_EXCEPTION
private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType INVALID_COUNT_EXCEPTION -
UNITS
-
-
Constructor Details
-
TimeArgumentType
public TimeArgumentType()
-
-
Method Details
-
time
-
parse
public Integer parse(com.mojang.brigadier.StringReader stringReader) throws com.mojang.brigadier.exceptions.CommandSyntaxException- Specified by:
parse
in interfacecom.mojang.brigadier.arguments.ArgumentType<Integer>
- 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:
listSuggestions
in interfacecom.mojang.brigadier.arguments.ArgumentType<Integer>
-
getExamples
- Specified by:
getExamples
in interfacecom.mojang.brigadier.arguments.ArgumentType<Integer>
-