Package net.minecraft.command.argument
Class ItemPredicateArgumentType
java.lang.Object
net.minecraft.command.argument.ItemPredicateArgumentType
- All Implemented Interfaces:
com.mojang.brigadier.arguments.ArgumentType<ItemPredicateArgumentType.ItemPredicateArgument>
public class ItemPredicateArgumentType extends Object implements com.mojang.brigadier.arguments.ArgumentType<ItemPredicateArgumentType.ItemPredicateArgument>
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static classItemPredicateArgumentType.ItemPredicatestatic interfaceItemPredicateArgumentType.ItemPredicateArgument(package private) static classItemPredicateArgumentType.TagPredicate -
Field Summary
Fields Modifier and Type Field Description private static Collection<String>EXAMPLESprivate static com.mojang.brigadier.exceptions.DynamicCommandExceptionTypeUNKNOWN_TAG_EXCEPTION -
Constructor Summary
Constructors Constructor Description ItemPredicateArgumentType() -
Method Summary
Modifier and Type Method Description Collection<String>getExamples()static Predicate<ItemStack>getItemPredicate(com.mojang.brigadier.context.CommandContext<ServerCommandSource> context, String name)static ItemPredicateArgumentTypeitemPredicate()<S> CompletableFuture<com.mojang.brigadier.suggestion.Suggestions>listSuggestions(com.mojang.brigadier.context.CommandContext<S> context, com.mojang.brigadier.suggestion.SuggestionsBuilder builder)ItemPredicateArgumentType.ItemPredicateArgumentparse(com.mojang.brigadier.StringReader stringReader)
-
Field Details
-
EXAMPLES
-
UNKNOWN_TAG_EXCEPTION
private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType UNKNOWN_TAG_EXCEPTION
-
-
Constructor Details
-
ItemPredicateArgumentType
public ItemPredicateArgumentType()
-
-
Method Details
-
itemPredicate
-
parse
public ItemPredicateArgumentType.ItemPredicateArgument parse(com.mojang.brigadier.StringReader stringReader) throws com.mojang.brigadier.exceptions.CommandSyntaxException- Specified by:
parsein interfacecom.mojang.brigadier.arguments.ArgumentType<ItemPredicateArgumentType.ItemPredicateArgument>- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getItemPredicate
public static Predicate<ItemStack> getItemPredicate(com.mojang.brigadier.context.CommandContext<ServerCommandSource> context, String name) -
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:
listSuggestionsin interfacecom.mojang.brigadier.arguments.ArgumentType<ItemPredicateArgumentType.ItemPredicateArgument>
-
getExamples
- Specified by:
getExamplesin interfacecom.mojang.brigadier.arguments.ArgumentType<ItemPredicateArgumentType.ItemPredicateArgument>
-