CurrentRun.ref()
CurrentRun.ref
has two important jobs.
First, it's used to reference the output of tasks within your project. Remember, tasks have to return a non-null output (either themselves, if the task is a decorated function or via their run method if the task is a class). At runtime, Prism stores references to these outputted objects and makes them accessible via CurrentRun.ref(...)
.
Second, it's used to build a dependency graph between tasks. Put another way, Prism parses the CurrentRef.ref(...)
calls and figures out the order in which tasks need to be run — if taskB
calls CurrentRef.ref("taskA")
in its body, then Prism knows to run taskA
before taskB
.
Here's the full method definition:
Example
Last updated