Struct governor::clock::QuantaInstant
source · pub struct QuantaInstant(/* private fields */);
Expand description
A nanosecond-scale opaque instant (already scaled to reference time) returned from a
QuantaClock
.
Trait Implementations§
source§impl Add<Nanos> for QuantaInstant
impl Add<Nanos> for QuantaInstant
§type Output = QuantaInstant
type Output = QuantaInstant
The resulting type after applying the
+
operator.source§impl Clone for QuantaInstant
impl Clone for QuantaInstant
source§fn clone(&self) -> QuantaInstant
fn clone(&self) -> QuantaInstant
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 QuantaInstant
impl Debug for QuantaInstant
source§impl Ord for QuantaInstant
impl Ord for QuantaInstant
source§fn cmp(&self, other: &QuantaInstant) -> Ordering
fn cmp(&self, other: &QuantaInstant) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq for QuantaInstant
impl PartialEq for QuantaInstant
source§fn eq(&self, other: &QuantaInstant) -> bool
fn eq(&self, other: &QuantaInstant) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for QuantaInstant
impl PartialOrd for QuantaInstant
source§fn partial_cmp(&self, other: &QuantaInstant) -> Option<Ordering>
fn partial_cmp(&self, other: &QuantaInstant) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl Reference for QuantaInstant
impl Reference for QuantaInstant
source§fn duration_since(&self, earlier: Self) -> Nanos
fn duration_since(&self, earlier: Self) -> Nanos
Determines the time that separates two measurements of a
clock. Implementations of this must perform a saturating
subtraction - if the
earlier
timestamp should be later,
duration_since
must return the zero duration.source§fn saturating_sub(&self, duration: Nanos) -> Self
fn saturating_sub(&self, duration: Nanos) -> Self
Returns a reference point that lies at most
duration
in the
past from the current reference. If an underflow should occur,
returns the current reference.impl Copy for QuantaInstant
impl Eq for QuantaInstant
impl StructuralPartialEq for QuantaInstant
Auto Trait Implementations§
impl Freeze for QuantaInstant
impl RefUnwindSafe for QuantaInstant
impl Send for QuantaInstant
impl Sync for QuantaInstant
impl Unpin for QuantaInstant
impl UnwindSafe for QuantaInstant
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
source§impl<T> CloneToUninit for Twhere
T: Copy,
impl<T> CloneToUninit for Twhere
T: Copy,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)