Package net.minecraft.command.arguments
Class OperationArgument
- java.lang.Object
-
- net.minecraft.command.arguments.OperationArgument
-
- All Implemented Interfaces:
com.mojang.brigadier.arguments.ArgumentType<OperationArgument.IOperation>
public class OperationArgument extends java.lang.Object implements com.mojang.brigadier.arguments.ArgumentType<OperationArgument.IOperation>
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static interface
OperationArgument.IIntOperation
static interface
OperationArgument.IOperation
-
Field Summary
Fields Modifier and Type Field Description private static com.mojang.brigadier.exceptions.SimpleCommandExceptionType
ERROR_DIVIDE_BY_ZERO
private static com.mojang.brigadier.exceptions.SimpleCommandExceptionType
ERROR_INVALID_OPERATION
private static java.util.Collection<java.lang.String>
EXAMPLES
-
Constructor Summary
Constructors Constructor Description OperationArgument()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Collection<java.lang.String>
getExamples()
static OperationArgument.IOperation
getOperation(com.mojang.brigadier.context.CommandContext<CommandSource> p_197179_0_, java.lang.String p_197179_1_)
private static OperationArgument.IOperation
getOperation(java.lang.String p_197177_0_)
private static OperationArgument.IIntOperation
getSimpleOperation(java.lang.String p_197182_0_)
<S> java.util.concurrent.CompletableFuture<com.mojang.brigadier.suggestion.Suggestions>
listSuggestions(com.mojang.brigadier.context.CommandContext<S> p_listSuggestions_1_, com.mojang.brigadier.suggestion.SuggestionsBuilder p_listSuggestions_2_)
static OperationArgument
operation()
OperationArgument.IOperation
parse(com.mojang.brigadier.StringReader p_parse_1_)
-
-
-
Field Detail
-
EXAMPLES
private static final java.util.Collection<java.lang.String> EXAMPLES
-
ERROR_INVALID_OPERATION
private static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType ERROR_INVALID_OPERATION
-
ERROR_DIVIDE_BY_ZERO
private static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType ERROR_DIVIDE_BY_ZERO
-
-
Method Detail
-
operation
public static OperationArgument operation()
-
getOperation
public static OperationArgument.IOperation getOperation(com.mojang.brigadier.context.CommandContext<CommandSource> p_197179_0_, java.lang.String p_197179_1_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
parse
public OperationArgument.IOperation parse(com.mojang.brigadier.StringReader p_parse_1_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Specified by:
parse
in interfacecom.mojang.brigadier.arguments.ArgumentType<OperationArgument.IOperation>
- 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> p_listSuggestions_1_, com.mojang.brigadier.suggestion.SuggestionsBuilder p_listSuggestions_2_)
- Specified by:
listSuggestions
in interfacecom.mojang.brigadier.arguments.ArgumentType<OperationArgument.IOperation>
-
getExamples
public java.util.Collection<java.lang.String> getExamples()
- Specified by:
getExamples
in interfacecom.mojang.brigadier.arguments.ArgumentType<OperationArgument.IOperation>
-
getOperation
private static OperationArgument.IOperation getOperation(java.lang.String p_197177_0_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getSimpleOperation
private static OperationArgument.IIntOperation getSimpleOperation(java.lang.String p_197182_0_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
-