pub struct ScriptedUnderstanding { /* private fields */ }Expand description
A TurnUnderstander that returns the understandings queued, in order, and keeps
what each turn showed it.
A turn with nothing queued is unreadable, with the code unscripted, so an extra
turn shows up as a turn that did nothing instead of an improvised reading.
Implementations§
Source§impl ScriptedUnderstanding
impl ScriptedUnderstanding
Sourcepub fn then(self, understanding: Understanding) -> Self
pub fn then(self, understanding: Understanding) -> Self
Queues understanding for the next turn.
Sourcepub fn push(&self, understanding: Understanding)
pub fn push(&self, understanding: Understanding)
Queues understanding for the next turn, after construction.
Sourcepub fn seen(&self) -> Vec<UnderstandingInput>
pub fn seen(&self) -> Vec<UnderstandingInput>
What each turn showed understanding, in order.
Trait Implementations§
Source§impl Debug for ScriptedUnderstanding
impl Debug for ScriptedUnderstanding
Source§impl Default for ScriptedUnderstanding
impl Default for ScriptedUnderstanding
Source§impl TurnUnderstander for ScriptedUnderstanding
impl TurnUnderstander for ScriptedUnderstanding
Source§fn understand<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
_scope: &'life1 TaskScope,
turn: &'life2 UnderstandingInput,
_steps: &'life3 dyn StepSink,
_checker: &'life4 dyn ActChecker,
) -> Pin<Box<dyn Future<Output = Understanding> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
fn understand<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
&'life0 self,
_scope: &'life1 TaskScope,
turn: &'life2 UnderstandingInput,
_steps: &'life3 dyn StepSink,
_checker: &'life4 dyn ActChecker,
) -> Pin<Box<dyn Future<Output = Understanding> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
'life4: 'async_trait,
Understands one turn, recording its calls in
scope and its steps in steps,
with the domain’s own check of each act.Auto Trait Implementations§
impl !Freeze for ScriptedUnderstanding
impl RefUnwindSafe for ScriptedUnderstanding
impl Send for ScriptedUnderstanding
impl Sync for ScriptedUnderstanding
impl Unpin for ScriptedUnderstanding
impl UnsafeUnpin for ScriptedUnderstanding
impl UnwindSafe for ScriptedUnderstanding
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