Seed<TData> class
sealed
Initial data to populate a query's cache before the first fetch.
Provide the data directly with Seed.value, or lazily with Seed.lazy when producing it is expensive (e.g. reading another query's cache).
A seed is applied only while the query has no data yet; data already in the cache is never overwritten by a seed.
Class hierarchy:
Seed (sealed)
├── SeedValue
└── SeedLazy
Constructors
- Seed.lazy(TData? resolve())
-
Seeds the query cache with the value returned by
resolve.constfactory - Seed.value(TData value)
-
Seeds the query cache with
value.constfactory
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
-
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