pub struct TimeMillis(pub i64);Tuple Fields§
§0: i64Implementations§
Source§impl TimeMillis
impl TimeMillis
pub const MAX: Self
pub const MIN: Self
pub fn zero() -> Self
pub fn random() -> TimeMillis
pub fn saturating_add(self, other: DurationMillis) -> TimeMillis
pub fn saturating_sub_duration(self, other: DurationMillis) -> TimeMillis
pub fn saturating_sub_time(self, other: TimeMillis) -> DurationMillis
pub fn as_secs(&self) -> i64
pub fn part_nanos(&self) -> i64
pub fn encode_be(self) -> TimeMillisBytes
pub fn timestamp_decode_be(timestamp_bytes: &TimeMillisBytes) -> Self
pub fn from_epoch_offset_str(duration_millis_str: &str) -> Result<Self>
Trait Implementations§
Source§impl Add<Duration> for TimeMillis
impl Add<Duration> for TimeMillis
Source§impl Add<DurationMillis> for TimeMillis
impl Add<DurationMillis> for TimeMillis
Source§type Output = TimeMillis
type Output = TimeMillis
The resulting type after applying the
+ operator.Source§impl Clone for TimeMillis
impl Clone for TimeMillis
Source§fn clone(&self) -> TimeMillis
fn clone(&self) -> TimeMillis
Returns a duplicate 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 TimeMillis
impl Debug for TimeMillis
Source§impl<'de> Deserialize<'de> for TimeMillis
impl<'de> Deserialize<'de> for TimeMillis
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for TimeMillis
impl Display for TimeMillis
Source§impl From<SystemTime> for TimeMillis
impl From<SystemTime> for TimeMillis
Source§fn from(time: SystemTime) -> Self
fn from(time: SystemTime) -> Self
Converts to this type from the input type.
Source§impl Hash for TimeMillis
impl Hash for TimeMillis
Source§impl Mul<Duration> for TimeMillis
impl Mul<Duration> for TimeMillis
Source§impl Ord for TimeMillis
impl Ord for TimeMillis
Source§fn cmp(&self, other: &TimeMillis) -> Ordering
fn cmp(&self, other: &TimeMillis) -> 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 TimeMillis
impl PartialEq for TimeMillis
Source§impl PartialOrd for TimeMillis
impl PartialOrd for TimeMillis
Source§impl Serialize for TimeMillis
impl Serialize for TimeMillis
Source§impl Sub<DurationMillis> for TimeMillis
impl Sub<DurationMillis> for TimeMillis
Source§type Output = TimeMillis
type Output = TimeMillis
The resulting type after applying the
- operator.Source§impl Sub for TimeMillis
impl Sub for TimeMillis
Source§type Output = DurationMillis
type Output = DurationMillis
The resulting type after applying the
- operator.Source§impl SubAssign<DurationMillis> for TimeMillis
impl SubAssign<DurationMillis> for TimeMillis
Source§fn sub_assign(&mut self, rhs: DurationMillis)
fn sub_assign(&mut self, rhs: DurationMillis)
Performs the
-= operation. Read moreimpl Copy for TimeMillis
impl Eq for TimeMillis
impl StructuralPartialEq for TimeMillis
Auto Trait Implementations§
impl Freeze for TimeMillis
impl RefUnwindSafe for TimeMillis
impl Send for TimeMillis
impl Sync for TimeMillis
impl Unpin for TimeMillis
impl UnsafeUnpin for TimeMillis
impl UnwindSafe for TimeMillis
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,
§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.