Repository navigation
https://pub.dev/packages/rx_storage/versions/4.0.0
Dependencies
-
Update dependencies:
rxdart_extfrom^0.3.0to^0.4.0.stack_tracefrom^1.10.0to^1.11.1.
-
Breaking: require Dart SDK
>=3.0.0 <4.0.0; Dart 2 is no longer supported.
Changes
-
Breaking: enforce inheritance and implementation restrictions with Dart 3
class modifiers:Storage,TransactionalStorage,RxStorage,RxStorageLogger, and
RxStorageLoggerEventare nowabstract interfaceclasses. Implement these
contracts instead of extending them.RealRxStorage,RxStorageDefaultLogger, andRxStorageEmptyLoggerare now
baseclasses. Extend them to reuse their implementation, and mark subclasses
asbase,final, orsealed.KeyAndValue,RxStorageError, and the concrete logger event classes are now
final. Define custom logger events by implementingRxStorageLoggerEvent.
-
Breaking: remove the deprecated
RxStorage.executeUpdateAPI and its
RealRxStorageimplementation. Useupdatewith named arguments (key,
decoder,transformer,encoder, and optionaloptions) instead. -
Breaking:
Storage.readAll()andRxStorage.observeAll()now require
anEntryDecoder<Key>callback and return maps of decoded values. The
callback receives both the key and its stored value and supports asynchronous
decoding. Pass(key, raw) => rawto retain the previous raw-value behavior.
Null decoding results retain their keys; removed keys are omitted from maps. -
Add the built-in
InMemoryStorage<Key>adapter with synchronous and
asynchronous encoder/decoder support. Encoded null values retain their keys;
remove()deletes entries, andreadAll()decodes a shallow entry
snapshot into a new map.
Fixes
- Reject queued writes with
StateErroron disposal instead of leaving their
futures pending. Started operations can finish without further notifications
or logs. - Retain asynchronous adapter initialization failures for later operations
without emitting an uncaught error before the first operation starts. - Run external disposal cleanup at most once and share its result across
concurrent and repeateddispose()calls. - Release idle write queues after synchronous task failures.
Docs
- Clarify the README and illustrate stream emissions with a timeline diagram.
- Exclude repository tooling, image prompts, and generated output from the
published package.
What's Changed
Full Changelog: 3.0.0...4.0.0