pub struct Transition {
pub target: String,
pub guard: Arc<dyn Fn(&State) -> bool + Send + Sync>,
pub description: Option<String>,
}Expand description
A guard-based transition to a named target phase.
Fields§
§target: StringName of the target phase.
guard: Arc<dyn Fn(&State) -> bool + Send + Sync>Guard function — transition fires when this returns true.
description: Option<String>Optional human-readable description of when/why this transition fires.
Used by describe_navigation() to tell the model what paths are available.
Auto Trait Implementations§
impl Freeze for Transition
impl !RefUnwindSafe for Transition
impl Send for Transition
impl Sync for Transition
impl Unpin for Transition
impl !UnwindSafe for Transition
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