pub struct Turn { /* private fields */ }Expand description
The fold’s record of one turn, built from its turn events.
Implementations§
Source§impl Turn
impl Turn
Sourcepub fn command_id(&self) -> Option<&str>
pub fn command_id(&self) -> Option<&str>
The commandId the fold took from the turn’s events: set by
turn/started while the turn runs, by turn/unqueued in any state,
and by turn/retracted in any state (a declined one only on a turn the
fold already holds). None before the fold applied one of them.
Sourcepub fn terminal(&self) -> Option<&str>
pub fn terminal(&self) -> Option<&str>
The terminal of the turn/completed the fold applied, verbatim, so
a newer host’s value survives; None until then. A retract or reclaim
keeps a terminal the turn already carries, so a Retracted or
Unqueued turn has one when its completion came first. A
turn/completed after an accepted retract or a reclaim is dropped; a
declined retract leaves a running turn for its completion to settle.
Sourcepub const fn completion(&self) -> Option<&Value>
pub const fn completion(&self) -> Option<&Value>
The full params of that turn/completed, or None until the fold
applied one.