pub struct PositiveMonotonicInstant(/* private fields */);
Expand description
A positive monotonic instant.
Implementations§
Source§impl PositiveMonotonicInstant
impl PositiveMonotonicInstant
Sourcepub const INFINITE_FUTURE: Self = _
pub const INFINITE_FUTURE: Self = _
An instant in the infinite future.
Sourcepub const fn into_nanos(self) -> i64
pub const fn into_nanos(self) -> i64
Returns the nanoseconds value for the instant.
Sourcepub const fn from_nanos(v: i64) -> Option<Self>
pub const fn from_nanos(v: i64) -> Option<Self>
Returns the the positive nanoseconds value from the monotonic timestamp in nanoseconds, if it’s positive.
Sourcepub fn is_infinite(&self) -> bool
pub fn is_infinite(&self) -> bool
Returns true if self
is equal to INFINITE_FUTURE
.
Trait Implementations§
Source§impl Clone for PositiveMonotonicInstant
impl Clone for PositiveMonotonicInstant
Source§fn clone(&self) -> PositiveMonotonicInstant
fn clone(&self) -> PositiveMonotonicInstant
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 PositiveMonotonicInstant
impl Debug for PositiveMonotonicInstant
Source§impl From<PositiveMonotonicInstant> for MonotonicInstant
impl From<PositiveMonotonicInstant> for MonotonicInstant
Source§fn from(PositiveMonotonicInstant: PositiveMonotonicInstant) -> Self
fn from(PositiveMonotonicInstant: PositiveMonotonicInstant) -> Self
Converts to this type from the input type.
Source§impl From<PositiveMonotonicInstant> for zx_time_t
impl From<PositiveMonotonicInstant> for zx_time_t
Source§fn from(value: PositiveMonotonicInstant) -> Self
fn from(value: PositiveMonotonicInstant) -> Self
Converts to this type from the input type.
Source§impl Hash for PositiveMonotonicInstant
impl Hash for PositiveMonotonicInstant
Source§impl Ord for PositiveMonotonicInstant
impl Ord for PositiveMonotonicInstant
Source§fn cmp(&self, other: &PositiveMonotonicInstant) -> Ordering
fn cmp(&self, other: &PositiveMonotonicInstant) -> 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 PositiveMonotonicInstant
impl PartialEq for PositiveMonotonicInstant
Source§impl PartialOrd for PositiveMonotonicInstant
impl PartialOrd for PositiveMonotonicInstant
Source§impl TryFrom<Instant<MonotonicTimeline>> for PositiveMonotonicInstant
impl TryFrom<Instant<MonotonicTimeline>> for PositiveMonotonicInstant
Source§type Error = NotPositiveMonotonicInstantError
type Error = NotPositiveMonotonicInstantError
The type returned in the event of a conversion error.
Source§impl TryFrom<i64> for PositiveMonotonicInstant
impl TryFrom<i64> for PositiveMonotonicInstant
impl Copy for PositiveMonotonicInstant
impl Eq for PositiveMonotonicInstant
impl StructuralPartialEq for PositiveMonotonicInstant
Auto Trait Implementations§
impl Freeze for PositiveMonotonicInstant
impl RefUnwindSafe for PositiveMonotonicInstant
impl Send for PositiveMonotonicInstant
impl Sync for PositiveMonotonicInstant
impl Unpin for PositiveMonotonicInstant
impl UnwindSafe for PositiveMonotonicInstant
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: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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
)