pub struct ProcessReduction<TState, TEvent, TEffect> {
pub state: TState,
pub events: Vec<ProcessEventDraft<TEvent>>,
pub effects: Vec<ProcessEffectRequestDraft<TEffect>>,
}Expand description
ProcessReduction data container.
Fields§
§state: TStatestate field for state.
events: Vec<ProcessEventDraft<TEvent>>events field for events.
effects: Vec<ProcessEffectRequestDraft<TEffect>>effects field for effects.
Implementations§
Source§impl<TState, TEvent, TEffect> ProcessReduction<TState, TEvent, TEffect>
impl<TState, TEvent, TEffect> ProcessReduction<TState, TEvent, TEffect>
Sourcepub fn with_events(self, events: Vec<ProcessEventDraft<TEvent>>) -> Self
pub fn with_events(self, events: Vec<ProcessEventDraft<TEvent>>) -> Self
Updates or reads with_events.
Sourcepub fn with_effects(
self,
effects: Vec<ProcessEffectRequestDraft<TEffect>>,
) -> Self
pub fn with_effects( self, effects: Vec<ProcessEffectRequestDraft<TEffect>>, ) -> Self
Updates or reads with_effects.
Trait Implementations§
Source§impl<TState: Clone, TEvent: Clone, TEffect: Clone> Clone for ProcessReduction<TState, TEvent, TEffect>
impl<TState: Clone, TEvent: Clone, TEffect: Clone> Clone for ProcessReduction<TState, TEvent, TEffect>
Source§fn clone(&self) -> ProcessReduction<TState, TEvent, TEffect>
fn clone(&self) -> ProcessReduction<TState, TEvent, TEffect>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<TState: Debug, TEvent: Debug, TEffect: Debug> Debug for ProcessReduction<TState, TEvent, TEffect>
impl<TState: Debug, TEvent: Debug, TEffect: Debug> Debug for ProcessReduction<TState, TEvent, TEffect>
Source§impl<TState: PartialEq, TEvent: PartialEq, TEffect: PartialEq> PartialEq for ProcessReduction<TState, TEvent, TEffect>
impl<TState: PartialEq, TEvent: PartialEq, TEffect: PartialEq> PartialEq for ProcessReduction<TState, TEvent, TEffect>
Source§fn eq(&self, other: &ProcessReduction<TState, TEvent, TEffect>) -> bool
fn eq(&self, other: &ProcessReduction<TState, TEvent, TEffect>) -> bool
Tests for
self and other values to be equal, and is used by ==.impl<TState, TEvent, TEffect> StructuralPartialEq for ProcessReduction<TState, TEvent, TEffect>
Auto Trait Implementations§
impl<TState, TEvent, TEffect> Freeze for ProcessReduction<TState, TEvent, TEffect>where
TState: Freeze,
impl<TState, TEvent, TEffect> RefUnwindSafe for ProcessReduction<TState, TEvent, TEffect>
impl<TState, TEvent, TEffect> Send for ProcessReduction<TState, TEvent, TEffect>
impl<TState, TEvent, TEffect> Sync for ProcessReduction<TState, TEvent, TEffect>
impl<TState, TEvent, TEffect> Unpin for ProcessReduction<TState, TEvent, TEffect>
impl<TState, TEvent, TEffect> UnsafeUnpin for ProcessReduction<TState, TEvent, TEffect>where
TState: UnsafeUnpin,
impl<TState, TEvent, TEffect> UnwindSafe for ProcessReduction<TState, TEvent, TEffect>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more