Class ItemParser

java.lang.Object
net.minecraft.commands.arguments.item.ItemParser

public class ItemParser extends Object
  • Field Details

    • ERROR_UNKNOWN_ITEM

      static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType ERROR_UNKNOWN_ITEM
    • ERROR_UNKNOWN_COMPONENT

      static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType ERROR_UNKNOWN_COMPONENT
    • ERROR_MALFORMED_COMPONENT

      static final com.mojang.brigadier.exceptions.Dynamic2CommandExceptionType ERROR_MALFORMED_COMPONENT
    • ERROR_EXPECTED_COMPONENT

      static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType ERROR_EXPECTED_COMPONENT
    • ERROR_REPEATED_COMPONENT

      static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType ERROR_REPEATED_COMPONENT
    • ERROR_MALFORMED_ITEM

      private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType ERROR_MALFORMED_ITEM
    • SYNTAX_START_COMPONENTS

      public static final char SYNTAX_START_COMPONENTS
      See Also:
    • SYNTAX_END_COMPONENTS

      public static final char SYNTAX_END_COMPONENTS
      See Also:
    • SYNTAX_COMPONENT_SEPARATOR

      public static final char SYNTAX_COMPONENT_SEPARATOR
      See Also:
    • SYNTAX_COMPONENT_ASSIGNMENT

      public static final char SYNTAX_COMPONENT_ASSIGNMENT
      See Also:
    • SYNTAX_REMOVED_COMPONENT

      public static final char SYNTAX_REMOVED_COMPONENT
      See Also:
    • SUGGEST_NOTHING

      static final Function<com.mojang.brigadier.suggestion.SuggestionsBuilder,CompletableFuture<com.mojang.brigadier.suggestion.Suggestions>> SUGGEST_NOTHING
    • items

    • registryOps

      final com.mojang.serialization.DynamicOps<Tag> registryOps
  • Constructor Details

  • Method Details

    • parse

      public ItemParser.ItemResult parse(com.mojang.brigadier.StringReader p_329942_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
      Throws:
      com.mojang.brigadier.exceptions.CommandSyntaxException
    • validateComponents

      private static void validateComponents(com.mojang.brigadier.StringReader p_331709_, Holder<Item> p_331328_, DataComponentPatch p_344694_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
      Throws:
      com.mojang.brigadier.exceptions.CommandSyntaxException
    • parse

      public void parse(com.mojang.brigadier.StringReader p_328566_, ItemParser.Visitor p_331669_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
      Throws:
      com.mojang.brigadier.exceptions.CommandSyntaxException
    • fillSuggestions

      public CompletableFuture<com.mojang.brigadier.suggestion.Suggestions> fillSuggestions(com.mojang.brigadier.suggestion.SuggestionsBuilder p_235310_)