MemoizedResult<R> class
Runs a multi-output bulk computation at most once, caching the result so multiple FunctionIndicators that each need one field of the same underlying call (e.g. Bollinger's upper/middle/lower, or MACD's macd/signal lines) share a single computation instead of repeating it.
Create one instance per indicator group (i.e. per Series built from
IndicatorConfig.getSeries()/createPainter()), not per line, and
capture it in each line's FunctionIndicator closure.
Constructors
-
MemoizedResult(R _compute(List<
IndicatorOHLC> bars, List<double> values)) - Initializes.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
call(
List< IndicatorOHLC> bars, List<double> values) → R -
Returns the cached result, computing it via
_computeon first call. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited