QueryCacheDescriptor class

Visual descriptor for a cached query record displayed in DevTools.

Contains cache key, staleness, expiration state, and timing metadata.

Example:

final descriptor = QueryCacheDescriptor(
  key: 'user:123',
  updatedAt: DateTime.now(),
  isStale: false,
  isExpired: false,
  staleTimeMs: 60000,
  cacheTimeMs: 300000,
  hasData: true,
);

Constructors

QueryCacheDescriptor({required String key, required DateTime updatedAt, required bool isStale, required bool isExpired, required int staleTimeMs, required int cacheTimeMs, required bool hasData})
Creates a QueryCacheDescriptor.

Properties

cacheTimeMs → int
Configured cache retention time in milliseconds.
final
hasData → bool
Whether non-null data is currently stored.
final
hashCode → int
The hash code for this object.
no setterinherited
isExpired → bool
Whether the entry has expired past its TTL.
final
isStale → bool
Whether the entry is considered stale.
final
key → String
Query cache key string.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
staleTimeMs → int
Configured stale time in milliseconds.
final
updatedAt → DateTime
Last updated timestamp.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() → Map<String, dynamic>
Serializes descriptor to a JSON map.
toString() → String
A string representation of this object.
inherited

Operators

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