redux_future_middleware library
Classes
-
FutureAction<
A, P> -
A
Redux
action class primarily used for dispatching an action containing Future. -
FutureFailedAction<
A> - An action class which is created by the Middleware for signalling that the current state of Future is completed and is unsuccessful, this class contains the error by Future in error property.
-
FuturePendingAction<
A> - An action class which is created by the Middleware for signalling that the current state of Future is incomplete.
-
FutureReducer<
State, Action, Payload> -
A utitlity
Reducer
class aimed at simplifying the boilerplate written in respective reducers for various FutureActions. - FutureReducerDefaults
- A class holding the defaults for FutureReducer.
-
FutureState<
State extends FutureState< State> > - Extend this class to create a base state class which handles the update logic for FuturePendingAction and FutureFailedAction for all the inheriting classes.
-
FutureSucceededAction<
A, P> - An action class which is created by the Middleware for signalling that the current state of Future is completed and is successful, this class contains the result of Future in payload property.
Functions
-
futureMiddleware<
State> (Store< State> store, dynamic action, NextDispatcher next) → void -
A
Redux
middleware for handling Dart Futures by creating a FutureAction. -
isActionOfFutureType<
A, P> (dynamic action) → bool - A utility function provided for checking if the action passed is of any of the Future Actions created above.