EffectStoreLike

Trait EffectStoreLike 

Source
pub trait EffectStoreLike<S, A: Action, E> {
    // Required methods
    fn dispatch(&mut self, action: A) -> DispatchResult<E>;
    fn state(&self) -> &S;
}
Expand description

Effect store interface used by EffectRuntime.

Required Methods§

Source

fn dispatch(&mut self, action: A) -> DispatchResult<E>

Dispatch an action and return state changes plus effects.

Source

fn state(&self) -> &S

Get the current state.

Implementors§

Source§

impl<S, A: Action, E> EffectStoreLike<S, A, E> for EffectStore<S, A, E>

Source§

impl<S, A: Action, E, M: Middleware<A>> EffectStoreLike<S, A, E> for EffectStoreWithMiddleware<S, A, E, M>