Engine<T> constructor
Engine<T> (
- RootState<
T> root, { - T? context,
- ExecutionStep<
T> ? step,
Creates an engine.
root
The RootState.
context
The data object.
step
The current step. If unspecified, creates a new, initial step.
Implementation
Engine(RootState<T> root, {T? context, ExecutionStep<T>? step})
// ignore: prefer_initializing_formals
: root = root,
_currentStep = step ?? ExecutionStep(root, context, History(root)) {
if (step == null) initialize();
}