pub struct StateDef {
pub id: i8,
pub enter: Callback,
pub update: Callback,
pub exit: Callback,
pub transitions: &'static [(i8, Callback)],
}Expand description
One state of a building’s state machine: its callbacks and its transitions.
Fields§
§id: i8The state’s number.
enter: CallbackThe callback when the state is entered.
update: CallbackThe callback at each scheduled update.
exit: CallbackThe callback when the state is left.
transitions: &'static [(i8, Callback)]The callbacks of transitions: the target state and its callback.
Auto Trait Implementations§
impl Freeze for StateDef
impl RefUnwindSafe for StateDef
impl Send for StateDef
impl Sync for StateDef
impl Unpin for StateDef
impl UnsafeUnpin for StateDef
impl UnwindSafe for StateDef
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