Class SignalExtensions
Pure combinators over ISignal<T> — the map/zip
rows of the domain spec's stream algebra (§10.4), specialised to a single
current value rather than a stream. Each result wraps its source(s)
lazily: reading Value re-evaluates from the
source's current value at read time, so there is no cached/stale copy to
keep in sync as the source changes.
public static class SignalExtensions
- Inheritance
-
SignalExtensions
- Inherited Members
Methods
Combine<TA, TB, TResult>(ISignal<TA>, ISignal<TB>, Func<TA, TB, TResult>)
Derive a signal from two signals' current values.
public static ISignal<TResult> Combine<TA, TB, TResult>(this ISignal<TA> left, ISignal<TB> right, Func<TA, TB, TResult> f)
Parameters
leftISignal<TA>The left source signal.
rightISignal<TB>The right source signal.
fFunc<TA, TB, TResult>Pure function combining both current values.
Returns
- ISignal<TResult>
Type Parameters
TAThe left source signal's value type.
TBThe right source signal's value type.
TResultThe derived signal's value type.
Remarks
Realises the zip combinator (§10.4) at the signal level.
Map<T, TResult>(ISignal<T>, Func<T, TResult>)
Derive a signal by applying a pure function to another signal's current value.
public static ISignal<TResult> Map<T, TResult>(this ISignal<T> signal, Func<T, TResult> f)
Parameters
signalISignal<T>The source signal.
fFunc<T, TResult>Pure function from the source value to the derived value.
Returns
- ISignal<TResult>
Type Parameters
TThe source signal's value type.
TResultThe derived signal's value type.
Remarks
Realises the map combinator (§10.4) at the signal level.