Class CommandFunctionManager.Execution

java.lang.Object
net.minecraft.server.function.CommandFunctionManager.Execution
Enclosing class:
CommandFunctionManager

private class CommandFunctionManager.Execution extends Object
An active execution of functions. It uses two deques to simulate a stack for a depth-first expansion of functions, as the function call stack depth may exceed the allowed JVM stack size.
See Also:
Mappings:
Namespace Name
official afk$a
intermediary net/minecraft/class_2991$class_6345
named net/minecraft/server/function/CommandFunctionManager$Execution
  • Field Details

    • depth

      private int depth
      Mappings:
      Namespace Name Mixin selector
      official b Lafk$a;b:I
      intermediary field_33545 Lnet/minecraft/class_2991$class_6345;field_33545:I
      named depth Lnet/minecraft/server/function/CommandFunctionManager$Execution;depth:I
    • tracer

      @Nullable private final @Nullable CommandFunctionManager.Tracer tracer
      Mappings:
      Namespace Name Mixin selector
      official c Lafk$a;c:Lafk$c;
      intermediary field_33546 Lnet/minecraft/class_2991$class_6345;field_33546:Lnet/minecraft/class_2991$class_6346;
      named tracer Lnet/minecraft/server/function/CommandFunctionManager$Execution;tracer:Lnet/minecraft/server/function/CommandFunctionManager$Tracer;
    • queue

      private final Deque<CommandFunctionManager.Entry> queue
      Mappings:
      Namespace Name Mixin selector
      official d Lafk$a;d:Ljava/util/Deque;
      intermediary field_33547 Lnet/minecraft/class_2991$class_6345;field_33547:Ljava/util/Deque;
      named queue Lnet/minecraft/server/function/CommandFunctionManager$Execution;queue:Ljava/util/Deque;
    • waitlist

      private final List<CommandFunctionManager.Entry> waitlist
      Mappings:
      Namespace Name Mixin selector
      official e Lafk$a;e:Ljava/util/List;
      intermediary field_33548 Lnet/minecraft/class_2991$class_6345;field_33548:Ljava/util/List;
      named waitlist Lnet/minecraft/server/function/CommandFunctionManager$Execution;waitlist:Ljava/util/List;
    • returned

      boolean returned
      Mappings:
      Namespace Name Mixin selector
      official f Lafk$a;f:Z
      intermediary field_44584 Lnet/minecraft/class_2991$class_6345;field_44584:Z
      named returned Lnet/minecraft/server/function/CommandFunctionManager$Execution;returned:Z
  • Constructor Details

    • Execution

      Execution(@Nullable @Nullable CommandFunctionManager.Tracer tracer)
      Mappings:
      Namespace Name Mixin selector
      official <init> Lafk$a;<init>(Lafk;Lafk$c;)V
      intermediary <init> Lnet/minecraft/class_2991$class_6345;<init>(Lnet/minecraft/class_2991;Lnet/minecraft/class_2991$class_6346;)V
      named <init> Lnet/minecraft/server/function/CommandFunctionManager$Execution;<init>(Lnet/minecraft/server/function/CommandFunctionManager;Lnet/minecraft/server/function/CommandFunctionManager$Tracer;)V
  • Method Details

    • recursiveRun

      void recursiveRun(CommandFunction function, ServerCommandSource source)
      Handles a recursive case in CommandFunctionManager.execute(CommandFunction, ServerCommandSource, CommandFunctionManager.Tracer, NbtCompound).

      This effectively swaps an entry with a command element with /function command at the head of the deque with another entry with a function element containing the actual command elements referenced in that function.

      Parameters:
      function - the function
      source - the command source
      Mappings:
      Namespace Name Mixin selector
      official a Lafk$a;a(Ldp;Ldt;)V
      intermediary method_36343 Lnet/minecraft/class_2991$class_6345;method_36343(Lnet/minecraft/class_2158;Lnet/minecraft/class_2168;)V
      named recursiveRun Lnet/minecraft/server/function/CommandFunctionManager$Execution;recursiveRun(Lnet/minecraft/server/function/CommandFunction;Lnet/minecraft/server/command/ServerCommandSource;)V
    • addReturnConsumer

      private ServerCommandSource addReturnConsumer(ServerCommandSource source)
      Mappings:
      Namespace Name Mixin selector
      official a Lafk$a;a(Ldt;)Ldt;
      intermediary method_51275 Lnet/minecraft/class_2991$class_6345;method_51275(Lnet/minecraft/class_2168;)Lnet/minecraft/class_2168;
      named addReturnConsumer Lnet/minecraft/server/function/CommandFunctionManager$Execution;addReturnConsumer(Lnet/minecraft/server/command/ServerCommandSource;)Lnet/minecraft/server/command/ServerCommandSource;
    • run

      int run(CommandFunction function, ServerCommandSource source)
      Parameters:
      function - the function
      source - the command source
      Returns:
      a value for the command result
      Mappings:
      Namespace Name Mixin selector
      official b Lafk$a;b(Ldp;Ldt;)I
      intermediary method_36346 Lnet/minecraft/class_2991$class_6345;method_36346(Lnet/minecraft/class_2158;Lnet/minecraft/class_2168;)I
      named run Lnet/minecraft/server/function/CommandFunctionManager$Execution;run(Lnet/minecraft/server/function/CommandFunction;Lnet/minecraft/server/command/ServerCommandSource;)I
    • reportError

      public void reportError(String message)
      Mappings:
      Namespace Name Mixin selector
      official a Lafk$a;a(Ljava/lang/String;)V
      intermediary method_36344 Lnet/minecraft/class_2991$class_6345;method_36344(Ljava/lang/String;)V
      named reportError Lnet/minecraft/server/function/CommandFunctionManager$Execution;reportError(Ljava/lang/String;)V