NavigationMachine<S, E, T> class

State machine managing navigation

Mixed-in types

Constructors

Properties

activeStateId → S?
no setterinherited
actualMonitorCreators → MonitorCreators
no setterinherited
data ↔ dynamic
Holds data arrived with fire. TODO: Is it the best way to access data from the machine?
getter/setter pairinherited
events List<E>
finalinherited
hashCode int
The hash code for this object.
no setterinherited
hasListeners bool
Whether any listeners are currently registered.
no setterinherited
history → HistoryLevel?
finalinherited
initialStateId → S
finalinherited
name String
State machine name.
finalinherited
notifyRegion Future<void> Function(Message)?
This callback is invoked when transitioning to an ExitPoint. It is implemented by the enclosing Region. We need to bubble the exitPointId (and the arg coming with the triggering event) up to the enclosing Region where exitConnectors will define the event that must be bubble up to the parent state and then state machine to fire with this event.
getter/setter pairinherited
parent ↔ Machine?
Parent machine.
getter/setter pairinherited
routerDelegate HismaRouterDelegate<S, E>
no getter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
states → StateMap<S, E, T>
finalinherited
transitions → TransitionMap<T, S>
finalinherited

Methods

addListener(VoidCallback listener) → void
Register a closure to be called when the object changes.
inherited
addMonitors(MonitorCreators monitorCreators) → void
inherited
dispose() → void
Discards any resources used by the object. After this is called, the object is not in a usable state and should be discarded (calls to addListener will throw after the object is disposed).
inherited
find<S1, E1, T1>(String name) NavigationMachine<S1, E1, T1>
fire(E eventId, {BuildContext? context, dynamic arg}) Future<void>
getActiveStateRecursive() List
Creates an array representing the active states of this state machine and recursively all compounded state machines where an array means one state machine where the 1st item is the state identifier and this array can contain zero or more sub state machines (regions) that are again defined as an array.
inherited
getStructureRecursive({bool includeInactive = true}) List
Creates an array representing the structure of the machine along with its states and recursively all compounded state machines with their respective states. Active states are represented by (*) after their state id.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notifyListeners() → void
Call all the registered listeners.
inherited
removeListener(VoidCallback listener) → void
Remove a previously registered closure from the list of closures that are notified when the object changes.
inherited
start({S? entryPointId, dynamic arg}) Future<void>
stateAt(S stateId) → State<E, T, S>?
Convenience method to give back either a State or null.
inherited
stop({dynamic arg}) Future<void>
Stopping the state machine also exiting active state and recursively stopping all potential child machines.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited