WalletCoordinatorActor class

The canonical public interface for third-party apps using LibSpiffy.

Receives coordinator commands, delegates to internal actors, tracks correlations, and emits events on a broadcast stream.

Apps interact with LibSpiffy exclusively through this actor:

  • Send commands via coordinator.tell(CreateWalletCommand(...))
  • Subscribe to events via libspiffy.coordinatorEvents.listen(...)

Constructors

WalletCoordinatorActor({required ActorRef walletManager, required ActorRef invoiceCoordinator, required ActorRef paymentCoordinator, required ActorRef spvActor, required ActorRef arcActor, required ActorRef headerSyncActor, required ActorRef benfordCoordinator, required ActorRef channelManager, required ActorRef walletProjection, @Deprecated('Unused: import progress arrives on importNotifications, and ' 'imports run through importWalletFromXpriv/importWalletFromWif. Kept ' 'so existing callers still compile; will be removed in a future ' 'release.') ActorRef? importActor, required ReadModelStorage storage, Stream<ChannelEvent>? channelEvents, Stream<Event>? readModelEvents, String peerId = '', ChannelTiming? channelTiming, Duration deadlineSweepInterval = const Duration(minutes: 1), dynamic importWalletFromXpriv({int addressGapLimit, String networkType, required String walletId, required String walletName, required String xpriv})?, dynamic importWalletFromWif({String networkType, required String walletId, required String walletName, required String wif})?, dynamic resumeWalletImport({int addressGapLimit, String networkType, required String walletId, required String walletName})?, Stream<WalletImportNotification>? importNotifications})

Properties

events → Stream<CoordinatorEvent>
Get the coordinator's event stream
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
onError(Object error, StackTrace stackTrace) → void
Called when an error occurs.
inherited
onMessage(dynamic message) → Future<void>
Called when a message is received.
postStop() → void
Release subscriptions, timers and the event stream when the actor is stopped without a ShutdownCommand (e.g. LibSpiffyActorSystem.shutdown in a host-owned actor system).
preStart() → void
Called when the actor is started.
stopAnnouncements() → Future<void>
Stops announcing balances and waits for an announcement already reading the read model to finish.
toString() → String
A string representation of this object.
inherited

Operators

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