ConsonaEventBus class

Domain event bus supporting exact and wildcard subscriptions.

Constructors

ConsonaEventBus()

Properties

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

Methods

clear() → void
Clears all registered listeners.
emit(String event, [Object? payload]) → void
Emits an event with optional payload to all matching subscribers.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
on(String pattern, ConsonaEventListener listener) → void Function()
Subscribes to events. Supports exact names (e.g. 'audio:play') or wildcards (e.g. '' or 'audio:').
toString() → String
A string representation of this object.
inherited

Operators

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