QueryCacheEvent class sealed Advanced

Something happened to a query in the cache: what QueryCache.subscribe delivers to its listeners.

Sealed, so a listener can switch over it exhaustively. The events are:

Events are for watching: logging, devtools, persisting the cache. To react to a fetch's outcome, the QueryCache constructor's onSuccess, onError and onSettled hooks are simpler.

Implementers
Annotations
  • @immutable

Properties

hashCode → int
The hash code for this object.
no setterinherited
query → Query<Object?>
The query the event is about. Typed as Query<Object?>, since a cache listener sees every key; read dataType or get<T> it from the cache to recover the concrete type.
final
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
toString() → String
A string representation of this object.
inherited

Operators

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