Class FunctionArgument

java.lang.Object
net.minecraft.command.arguments.FunctionArgument
All Implemented Interfaces:
com.mojang.brigadier.arguments.ArgumentType<FunctionArgument.IResult>

public class FunctionArgument extends Object implements com.mojang.brigadier.arguments.ArgumentType<FunctionArgument.IResult>
  • Field Details

    • EXAMPLES

      private static final Collection<String> EXAMPLES
    • ERROR_UNKNOWN_TAG

      private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType ERROR_UNKNOWN_TAG
    • ERROR_UNKNOWN_FUNCTION

      private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType ERROR_UNKNOWN_FUNCTION
  • Constructor Details

    • FunctionArgument

      public FunctionArgument()
  • Method Details

    • functions

      public static FunctionArgument functions()
    • parse

      public FunctionArgument.IResult parse(com.mojang.brigadier.StringReader p_parse_1_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
      Specified by:
      parse in interface com.mojang.brigadier.arguments.ArgumentType<FunctionArgument.IResult>
      Throws:
      com.mojang.brigadier.exceptions.CommandSyntaxException
    • getFunction

      private static FunctionObject getFunction(com.mojang.brigadier.context.CommandContext<CommandSource> p_218108_0_, ResourceLocation p_218108_1_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
      Throws:
      com.mojang.brigadier.exceptions.CommandSyntaxException
    • getFunctionTag

      private static ITag<FunctionObject> getFunctionTag(com.mojang.brigadier.context.CommandContext<CommandSource> p_218111_0_, ResourceLocation p_218111_1_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
      Throws:
      com.mojang.brigadier.exceptions.CommandSyntaxException
    • getFunctions

      public static Collection<FunctionObject> getFunctions(com.mojang.brigadier.context.CommandContext<CommandSource> p_200022_0_, String p_200022_1_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
      Throws:
      com.mojang.brigadier.exceptions.CommandSyntaxException
    • getFunctionOrTag

      public static com.mojang.datafixers.util.Pair<ResourceLocation,com.mojang.datafixers.util.Either<FunctionObject,ITag<FunctionObject>>> getFunctionOrTag(com.mojang.brigadier.context.CommandContext<CommandSource> p_218110_0_, String p_218110_1_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
      Throws:
      com.mojang.brigadier.exceptions.CommandSyntaxException
    • getExamples

      public Collection<String> getExamples()
      Specified by:
      getExamples in interface com.mojang.brigadier.arguments.ArgumentType<FunctionArgument.IResult>