Trait time2::DurationExt
[−]
[src]
pub trait DurationExt {
fn as_millis(&self) -> Option<u64>;
fn mul_u64(&self, rhs: u64) -> Self;
fn div_u64(&self, rhs: u64) -> Self;
}Extensions to the Duration type.
Required Methods
fn as_millis(&self) -> Option<u64>
Returns the number of whole milliseconds contained in this Duration.
Returns None if the value exceeds the capacity of a u64.
fn mul_u64(&self, rhs: u64) -> Self
Multiplies this Duration.
Like the Mul implementation for Duration, except that it takes a
u64 instead of a `u32.
fn div_u64(&self, rhs: u64) -> Self
Divides this Duration.
Like the Div implementation for Duration, except that it takes a
u64 instead of a u32.
Implementors
impl DurationExt for Duration