MCPcopy Create free account
hub / github.com/microsoft/SandDance / getPulse

Function getPulse

docs/app/js/sanddance-app.js:108585–108588  ·  view source on GitHub ↗

* Provide a correct pulse for evaluating an operator. If the operator has an * explicit source operator, we will try to pull the pulse(s) from it. * If there is an array of source operators, we build a multi-pulse. * Otherwise, we return a current pulse with correct source data. * If the pulse i

(op, encode)

Source from the content-addressed store, hash-verified

108583 * @param {string} [encode] - An (optional) encoding set name with which to
108584 * annotate the returned pulse. See {@link run} for more information.
108585 */ function getPulse(op, encode) {
108586 const s = op.source, stamp = this._clock;
108587 return s && (0, _vegaUtil.isArray)(s) ? new MultiPulse(this, stamp, s.map((_)=>_.pulse), encode) : this._input[op.id] || singlePulse(this._pulse, s && s.pulse);
108588}
108589function singlePulse(p, s) {
108590 if (s && s.stamp === p.stamp) return s;
108591 p = p.fork();

Callers

nothing calls this directly

Calls 1

singlePulseFunction · 0.70

Tested by

no test coverage detected