InteractionTracker class
Tracks and logs user interactions with adaptive widgets
Constructors
- InteractionTracker.new({StorageBackend? storage})
-
Factory constructor that accepts a custom storage backend
factory
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
-
onInteraction
→ Stream<
InteractionEvent> -
Stream of interaction events
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
addListener(
InteractionCallback callback) → void - Add a callback to be called when interactions occur
-
clearAllEvents(
) → Future< void> - Clear all interaction events
-
dispose(
) → void - Dispose the tracker
-
getAllEvents(
) → Future< List< InteractionEvent> > - Get all interaction events
-
getEventsForWidget(
String widgetId) → Future< List< InteractionEvent> > - Get all interaction events for a widget
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
removeListener(
InteractionCallback callback) → void - Remove a previously added callback
-
setStorageBackend(
StorageBackend storage) → void - Set the storage backend
-
toString(
) → String -
A string representation of this object.
inherited
-
trackInteraction(
String widgetId, InteractionType type, {dynamic value}) → Future< void> - Track a user interaction
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
- instance → InteractionTracker
-
Get the singleton instance of the interaction tracker
no setter