pub struct ReplayReducer { /* private fields */ }Expand description
Holds replay reducer application-layer state or configuration. Use it with the documented coordinator methods; run, journal, event, provider, or port effects are called out on those methods rather than on construction.
Implementations§
Source§impl ReplayReducer
impl ReplayReducer
Sourcepub fn new(mode: ReplayMode) -> Self
pub fn new(mode: ReplayMode) -> Self
Creates a new application::replay value with explicit caller-provided inputs. This constructor is data-only and performs no I/O or external side effects.
Sourcepub fn with_available_content_refs(
self,
refs: impl IntoIterator<Item = ContentRef>,
) -> Self
pub fn with_available_content_refs( self, refs: impl IntoIterator<Item = ContentRef>, ) -> Self
Returns this value with its available content refs setting replaced. The method follows builder-style data construction and does not execute external work.
Sourcepub fn with_missing_content_policy(self, policy: MissingContentPolicy) -> Self
pub fn with_missing_content_policy(self, policy: MissingContentPolicy) -> Self
Returns this value with its missing content policy setting replaced. The method follows builder-style data construction and does not execute external work.
Sourcepub fn apply(&mut self, record: JournalRecord) -> Result<(), AgentError>
pub fn apply(&mut self, record: JournalRecord) -> Result<(), AgentError>
Apply. This mutates only the replay projection with one journal record and never re-executes the recorded side effect.
Sourcepub fn finish(self) -> Result<ReplayResult, AgentError>
pub fn finish(self) -> Result<ReplayResult, AgentError>
Finish. This finalizes replay bookkeeping into a result and does not re-execute recorded effects.
Trait Implementations§
Source§impl Clone for ReplayReducer
impl Clone for ReplayReducer
Source§fn clone(&self) -> ReplayReducer
fn clone(&self) -> ReplayReducer
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more