the numbers used for relaying the status of a signal after it has been ran via its run method.
these numbers convey the following instructions to the context's topological update cycle Context.propagateSignalUpdate:
1: this signal's value has been updated, and therefore its observers should be updated too.
0: this signal's value has not changed, and therefore its observers should be not be updated.
do note that an observer signal will still run if some other of its dependency signal did update this cycle (i.e. had a status value of 1)
-1: this signal has been aborted, and therefore its observers must abort execution as well.
the observers will abort even if they had a dependency that did update (had a status value of 1)
to sum up, given a signal D, with dependencies: A, B, and C (all of which are mutually independent of each other).
then the status of D will be as follows in the order of highest conditional priority to lowest:
the numbers used for relaying the status of a signal after it has been ran via its
run method
.these numbers convey the following instructions to the context's topological update cycle Context.propagateSignalUpdate:
1
: this signal's value has been updated, and therefore its observers should be updated too.0
: this signal's value has not changed, and therefore its observers should be not be updated. do note that an observer signal will still run if some other of its dependency signal did update this cycle (i.e. had a status value of1
)-1
: this signal has been aborted, and therefore its observers must abort execution as well. the observers will abort even if they had a dependency that did update (had a status value of1
)to sum up, given a signal
D
, with dependencies:A
,B
, andC
(all of which are mutually independent of each other). then the status ofD
will be as follows in the order of highest conditional priority to lowest:status(D) = -1
ABORTED
∃X ∈ [A, B, C] such that status(X) === -1
status(D) = D.run()
CHANGED
orUNCHANGED
orABORTED
∃X ∈ [A, B, C] such that status(X) === 1
status(D) = 0
UNCHANGED
∀X ∈ [A, B, C], status(X) === 0