pub struct DispatchImpactAccumulator { /* private fields */ }Expand description
Lossless request-scoped accumulator for installed subcommit effects.
Implementations§
Source§impl DispatchImpactAccumulator
impl DispatchImpactAccumulator
Sourcepub fn record(
&mut self,
effect: DispatchEffect,
targets: impl IntoIterator<Item = DispatchTarget>,
)
pub fn record( &mut self, effect: DispatchEffect, targets: impl IntoIterator<Item = DispatchTarget>, )
Records one truthful effect after its durable subcommit is installed.
Repeated effects union exact target sets. An empty target iterator still records the effect because lack of a current binding does not erase a committed permission change.
Sourcepub fn merge(&mut self, prefix: Self)
pub fn merge(&mut self, prefix: Self)
Merges another installed-prefix accumulator without replacing any earlier effect or target.
Sourcepub fn finish(self, conversation_id: ConversationId) -> DispatchImpact
pub fn finish(self, conversation_id: ConversationId) -> DispatchImpact
Converts the request accumulator into its externally carried impact.
Trait Implementations§
Source§impl Debug for DispatchImpactAccumulator
impl Debug for DispatchImpactAccumulator
Source§impl Default for DispatchImpactAccumulator
impl Default for DispatchImpactAccumulator
Source§fn default() -> DispatchImpactAccumulator
fn default() -> DispatchImpactAccumulator
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for DispatchImpactAccumulator
impl RefUnwindSafe for DispatchImpactAccumulator
impl Send for DispatchImpactAccumulator
impl Sync for DispatchImpactAccumulator
impl Unpin for DispatchImpactAccumulator
impl UnsafeUnpin for DispatchImpactAccumulator
impl UnwindSafe for DispatchImpactAccumulator
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