Lifecycle class abstract

Designates a node as a Lifecycle node, meaning it has onStart and onStop methods. If you only need light construction without futures, it's better to just use the constructor.

Implemented types
Implementers
Available extensions

Constructors

Lifecycle()

Properties

$isRunning bool

Available on Lifecycle, provided by the XLifecycle extension

no setter
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
onStart() Future<void>
Called when the node is started. This is where you should initialize your node. If you are using a stateful node, your state was already loaded by this point
onStop() Future<void>
Called when the node is stopped. You may still write to your state as the node will save its state after this method is called.
toString() String
A string representation of this object.
inherited

Operators

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

Static Methods

$callStart(Node node, NodeStorage storage, PrecisionStopwatch wallClock) Future<void>
$callStop(Node node, NodeStorage storage, PrecisionStopwatch wallClock) Future<void>