Releases: hoc081098/rxdart
0.28.0
New
-
ValueStream:
- Add
lastEventOrNullgetter toValueStream,
which returns the last emitted event (either data/value or error event), ornull. - Add
isLastEventValue,isLastEventErroranderrorAndStackTraceOrNull
extension getters toValueStream, to check the kind of the last emitted event is data/value or error. - Update documentation.
- Add
-
ReplayStream:
- Add
errorAndStackTracestoReplayStream, which returns a list of emittedErrorAndStackTraces.
- Add
-
Rename
NotificationandKindto better reflect their purpose,
and to avoid confusion with Flutter's Notification class.- Rename
NotificationtoStreamNotificationNotification.onDatatoStreamNotification.data.Notification.onDonetoStreamNotification.done.Notification.onErrortoStreamNotification.error.
- Rename
KindtoNotificationKindKind.onDatatoNotificationKind.data.Kind.onErrortoNotificationKind.error.Kind.onDonetoNotificationKind.done.
- Introduce
DataNotification,ErrorNotificationandDoneNotificationas the subclasses ofStreamNotification. - Convert
isOnData,isOnError,isOnDone,requireDatato extension getters onStreamNotification,
they are now namedisData,isError,isDoneandrequireDataValue. - Add extensions on
StreamNotification:dataValueOrNull,requireErrorAndStackTrace,errorAndStackTraceOrNullgetters andwhenmethod.
- Rename
Changed
-
Accept Dart SDK versions above 3.0.
-
switchMap: when cancelling the previous inner subscription,
switchMapwill pause the outer subscription and and wait for the inner subscription to be completely canceled.
It will then resume the outer subscription, and listen to the next inner Stream.
Any errors from canceling the previous inner subscription will now be forwarded to the resulting Stream. -
Breaking: Rename
ForkJoinStream.combine2..combine9toForkJoinStream.join2..join9. -
Breaking:
Rx.using/UsingStream- Convert all required positional parameters to required named parameters.
- The
disposeris now called after the future returned fromStreamSubscription.cancelcompletes.
Documentation
- Update and fix documentation.
- Fix README example (thanks to @wurikiji).
- Update Flutter example (thanks to @hoangchungk53qx1).
- Replace deprecated "dart pub run" with "dart run" (thanks to @tatsuyafujisaki).
0.28.0-dev.2
Feedback on this change appreciated as this is a dev release before 0.28.0 stable!
Changed
- Breaking: Rename
ForkJoinStream.combine2..combine9toForkJoinStream.join2..join9. - Breaking:
Rx.using/UsingStream- Convert all required positional parameters to required named parameters.
- The
disposeris now called after the future returned fromStreamSubscription.cancelcompletes.