QueryObserverOptionsUpdated class final Advanced

An observer's options were replaced — a rebuild that changed staleTime, enabled or a callback, say. Emitted for every change of options, a key change included: moving an observer to a different key emits QueryObserverRemoved on the old query and QueryObserverAdded on the new one, and then this event on the new query. TanStack Query calls this event observerOptionsUpdated and orders it the same way.

Inheritance

Constructors

QueryObserverOptionsUpdated(Query<Object?> query, QueryObserverRef observer)
Creates the event for query and the observer whose options changed.
const

Properties

hashCode → int
The hash code for this object.
no setterinherited
observer → QueryObserverRef
The observer whose options changed. Read-only from outside.
final
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.
finalinherited
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