yarn/mappings/net/minecraft/util/PendingTaskRunner.mapping

16 lines
945 B
Plaintext

CLASS net/minecraft/class_7493 net/minecraft/util/PendingTaskRunner
COMMENT A runner for tasks that have a running state and can hold one pending task.
COMMENT
COMMENT <p>If there is no running tasks, calling {@link #run} will run the passed task
COMMENT and marks the runner as running. During this state, calling the run method will set
COMMENT the task as pending. If called multiple times, only the last task will be called.
COMMENT Calling {@link #runPending} forces it to run the pending task, if any.
FIELD field_39385 running Z
FIELD field_39386 pending Ljava/lang/Runnable;
METHOD method_44122 runPending ()V
COMMENT Runs the pending task, if any, and marks the runner as not running.
METHOD method_44123 run (Ljava/lang/Runnable;)V
COMMENT Runs the task and marks the runner as running if there is no running task,
COMMENT otherwise sets the task as the pending task. This overwrites the old pending task.
ARG 1 task