Package net.minecraft.command.arguments
Class ScoreHolderArgument
- java.lang.Object
-
- net.minecraft.command.arguments.ScoreHolderArgument
-
- All Implemented Interfaces:
com.mojang.brigadier.arguments.ArgumentType<ScoreHolderArgument.INameProvider>
public class ScoreHolderArgument extends java.lang.Object implements com.mojang.brigadier.arguments.ArgumentType<ScoreHolderArgument.INameProvider>
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
ScoreHolderArgument.INameProvider
static class
ScoreHolderArgument.NameProvider
static class
ScoreHolderArgument.Serializer
-
Field Summary
Fields Modifier and Type Field Description private static com.mojang.brigadier.exceptions.SimpleCommandExceptionType
ERROR_NO_RESULTS
private static java.util.Collection<java.lang.String>
EXAMPLES
private boolean
multiple
static com.mojang.brigadier.suggestion.SuggestionProvider<CommandSource>
SUGGEST_SCORE_HOLDERS
-
Constructor Summary
Constructors Constructor Description ScoreHolderArgument(boolean p_i47968_1_)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Collection<java.lang.String>
getExamples()
static java.lang.String
getName(com.mojang.brigadier.context.CommandContext<CommandSource> p_197211_0_, java.lang.String p_197211_1_)
static java.util.Collection<java.lang.String>
getNames(com.mojang.brigadier.context.CommandContext<CommandSource> p_197213_0_, java.lang.String p_197213_1_)
static java.util.Collection<java.lang.String>
getNames(com.mojang.brigadier.context.CommandContext<CommandSource> p_197210_0_, java.lang.String p_197210_1_, java.util.function.Supplier<java.util.Collection<java.lang.String>> p_197210_2_)
static java.util.Collection<java.lang.String>
getNamesWithDefaultWildcard(com.mojang.brigadier.context.CommandContext<CommandSource> p_211707_0_, java.lang.String p_211707_1_)
ScoreHolderArgument.INameProvider
parse(com.mojang.brigadier.StringReader p_parse_1_)
static ScoreHolderArgument
scoreHolder()
static ScoreHolderArgument
scoreHolders()
-
-
-
Field Detail
-
SUGGEST_SCORE_HOLDERS
public static final com.mojang.brigadier.suggestion.SuggestionProvider<CommandSource> SUGGEST_SCORE_HOLDERS
-
EXAMPLES
private static final java.util.Collection<java.lang.String> EXAMPLES
-
ERROR_NO_RESULTS
private static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType ERROR_NO_RESULTS
-
multiple
private final boolean multiple
-
-
Method Detail
-
getName
public static java.lang.String getName(com.mojang.brigadier.context.CommandContext<CommandSource> p_197211_0_, java.lang.String p_197211_1_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getNames
public static java.util.Collection<java.lang.String> getNames(com.mojang.brigadier.context.CommandContext<CommandSource> p_197213_0_, java.lang.String p_197213_1_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getNamesWithDefaultWildcard
public static java.util.Collection<java.lang.String> getNamesWithDefaultWildcard(com.mojang.brigadier.context.CommandContext<CommandSource> p_211707_0_, java.lang.String p_211707_1_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getNames
public static java.util.Collection<java.lang.String> getNames(com.mojang.brigadier.context.CommandContext<CommandSource> p_197210_0_, java.lang.String p_197210_1_, java.util.function.Supplier<java.util.Collection<java.lang.String>> p_197210_2_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
scoreHolder
public static ScoreHolderArgument scoreHolder()
-
scoreHolders
public static ScoreHolderArgument scoreHolders()
-
parse
public ScoreHolderArgument.INameProvider parse(com.mojang.brigadier.StringReader p_parse_1_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Specified by:
parse
in interfacecom.mojang.brigadier.arguments.ArgumentType<ScoreHolderArgument.INameProvider>
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getExamples
public java.util.Collection<java.lang.String> getExamples()
- Specified by:
getExamples
in interfacecom.mojang.brigadier.arguments.ArgumentType<ScoreHolderArgument.INameProvider>
-
-