FdcMemoryDataAdapter class

In-memory adapter for local rows, tests, demos, and small client-side data.

The adapter supports synchronous opening and evaluates supported filter, sort, search, paging, and aggregate operations against its in-memory rows.

Inheritance
Implemented types

Constructors

FdcMemoryDataAdapter({required List<Map<String, Object?>> rows, List<FdcDataAdapterFilter> filters = const <FdcDataAdapterFilter>[], List<FdcDataAdapterSort> sorts = const <FdcDataAdapterSort>[]})
Creates an in-memory adapter backed by rows.

Properties

capabilities → FdcDataAdapterCapabilities
Adapter-side operation capabilities.
no setterinherited
filters → List<FdcDataAdapterFilter>
Source-level filters that are always applied by datasets using this adapter.
finalinherited
hashCode → int
The hash code for this object.
no setterinherited
readOnly → bool
Whether this adapter exposes a non-committable data source.
finalinherited
rows → List<Map<String, Object?>>
Returns a defensive copy of the current adapter rows.
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
sorts → List<FdcDataAdapterSort>
Default source-level ordering used when the dataset/grid has no active user sort.
finalinherited

Methods

aggregate(FdcDataAggregateRequest request) → Future<FdcDataAggregateResult>
Calculates adapter-side aggregates over the full effective adapter result set. Subclasses that support aggregate queries override this and expose capabilities.aggregates == true.
override
aggregateSync(FdcDataAggregateRequest request) → FdcDataAggregateResult
Calculates aggregates synchronously against the in-memory rows.
applyUpdates(FdcChangeSet changes) → Future<FdcDataApplyResult>
Applies a dataset change set to the backend.
override
dispose() → void
Releases adapter-owned resources.
inherited
load(FdcDataLoadRequest request) → Future<FdcDataLoadResult>
Loads rows for the supplied request.
override
loadSync(FdcDataLoadRequest request) → FdcDataLoadResult
Loads data synchronously for adapters that support an immediate path.
override
mapApplyException(FdcChangeSetEntry entry, Object error, {required FdcDataApplyOperation operation}) → FdcDataApplyError
Converts an adapter/backend exception raised while applying one change entry into a structured row-level apply error.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
replaceRows(List<Map<String, Object?>> rows) → void
Replaces all rows managed by this adapter.
toString() → String
A string representation of this object.
inherited
validateStorageValue(FdcFieldDef field, Object? value) → String?
Validates a value against adapter/storage-level constraints.
inherited

Operators

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