pub struct Competition<R: Robot>(/* private fields */);Expand description
Competition state machine.
Implementations§
Source§impl<R: Robot> Competition<R>
impl<R: Robot> Competition<R>
Sourcepub fn initialize(&self) -> Promise
pub fn initialize(&self) -> Promise
Runs on initialization.
Sourcepub fn initialize_ext(&self, ctx: Context) -> Promise
pub fn initialize_ext(&self, ctx: Context) -> Promise
Runs on initialization.
Sourcepub fn autonomous(&self) -> Promise
pub fn autonomous(&self) -> Promise
Runs during the autonomous period.
Sourcepub fn autonomous_ext(&self, ctx: Context) -> Promise
pub fn autonomous_ext(&self, ctx: Context) -> Promise
Runs during the autonomous period.
Sourcepub fn opcontrol_ext(&self, ctx: Context) -> Promise
pub fn opcontrol_ext(&self, ctx: Context) -> Promise
Runs during the opcontrol period.
Sourcepub fn disabled_ext(&self, ctx: Context) -> Promise
pub fn disabled_ext(&self, ctx: Context) -> Promise
Runs when the robot is disabled.
Trait Implementations§
Source§impl<R: Robot> StateMachine for Competition<R>
impl<R: Robot> StateMachine for Competition<R>
Auto Trait Implementations§
impl<R> Freeze for Competition<R>
impl<R> !RefUnwindSafe for Competition<R>
impl<R> Send for Competition<R>
impl<R> Sync for Competition<R>
impl<R> Unpin for Competition<R>where
R: Unpin,
impl<R> !UnwindSafe for Competition<R>
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