pub struct StepContext {
pub position: i64,
pub step_time: Duration,
}
Expand description
Extra contextual information passed to a Device
when its
Device::step()
method is invoked.
Fields§
§position: i64
The new position, in steps.
step_time: Duration
The time (as dictated by crate::SystemClock::elapsed()
) this step
was taken.
Trait Implementations§
Source§impl Clone for StepContext
impl Clone for StepContext
Source§fn clone(&self) -> StepContext
fn clone(&self) -> StepContext
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for StepContext
impl Debug for StepContext
Source§impl PartialEq for StepContext
impl PartialEq for StepContext
impl StructuralPartialEq for StepContext
Auto Trait Implementations§
impl Freeze for StepContext
impl RefUnwindSafe for StepContext
impl Send for StepContext
impl Sync for StepContext
impl Unpin for StepContext
impl UnwindSafe for StepContext
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