onChange<T> method

  1. @override
void onChange<T>(
  1. Shard<T> shard,
  2. T previousState,
  3. T currentState
)
override

Called whenever a Shard's state changes.

shard is the shard instance that changed. previousState is the state before the change. currentState is the state after the change.

Implementation

@override
void onChange<T>(Shard<T> shard, T previousState, T currentState) {
  _changes.add(ObservedChange<T>(shard, previousState, currentState));
}