(<cget c)
(c-get c)
The API for determing the value associated with a Cell. Ensures value is current, records any dependent, and notices if a standalone cell has never been observed.
The API for determing the value associated with a Cell. Ensures value is current, records any dependent, and notices if a standalone cell has never been observed.
(c-quiesce c)
(c-value-assume c new-value propagation-code)
The Cell assumes a new value at awakening, on c-reset!, or after formula recalculation.
We record the new value, set the Cell state to :awake, make its pulse current, check to see if a formula cell can be optimized away, and then propagate to any dependent formula cells.
The Cell assumes a new value at awakening, on c-reset!, or after formula recalculation. We record the new value, set the Cell state to :awake, make its pulse current, check to see if a formula cell can be optimized away, and then propagate to any dependent formula cells.
(c-value-changed? c new-value old-value)
(calculate-and-link c)
The name is accurate: we do no more than invoke the rule of a formula and return its value*, but along the way the links between dependencies and dependents get determined anew.
The name is accurate: we do no more than invoke the rule of a formula and return its value*, but along the way the links between dependencies and dependents get determined anew. * Well, we also look to see if a synaptic cell has attached a propagaion code to a vector used to wrap the raw value, which we then unpack.
(calculate-and-set c dbgid dbgdata)
Calculate, link, record, and propagate.
Calculate, link, record, and propagate.
(ensure-value-is-current c debug-id ensurer)
The key to data integrity: recursively check the known dependency graph to decide if we are current, and if not kick off recalculation and propagation.
The key to data integrity: recursively check the known dependency graph to decide if we are current, and if not kick off recalculation and propagation.
(ephemeral-reset rc)
(md-cell-flush c)
(md-slot-value-store me slot value)
(not-to-be-self me)
(optimize-away?! c prior-value)
Optimizes away cells who turn out not to depend on anyone, saving a lot of work at runtime. A caller/user will not bother establishing a link, and when we get to models cget will find a non-cell in a slot and Just Use It.
Optimizes away cells who turn out not to depend on anyone, saving a lot of work at runtime. A caller/user will not bother establishing a link, and when we get to models cget will find a non-cell in a slot and Just Use It.
(propagate c prior-value callers)
A cell:
A cell: - notifies its callers of its change; - calls any observer; and - if ephemeral, silently reverts to nil.
(propagate-to-callers c callers)
Cells does not propagate when nothing changes. By default, the test is =, but cells can inject a different test, and when we get to models it will be possible for a slot to have associated with it a different test.
Cells does not propagate when nothing changes. By default, the test is =, but cells can inject a different test, and when we get to models it will be possible for a slot to have associated with it a different test.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close