pub struct Millisecond;
Expand description
A unit of time representing exactly one millisecond.
Implementations§
Source§impl Millisecond
impl Millisecond
Sourcepub const fn per<T>(_larger: T) -> <Millisecond as Per<T>>::Output
pub const fn per<T>(_larger: T) -> <Millisecond as Per<T>>::Output
Obtain the number of times Millisecond
can fit into T
.
If T
is smaller than Millisecond
, the code will fail to
compile. The return type is the smallest unsigned integer type that can represent
the value.
Valid calls:
Millisecond::per(Millisecond)
(returnsu8
)Millisecond::per(Second)
(returnsu16
)Millisecond::per(Minute)
(returnsu16
)Millisecond::per(Hour)
(returnsu32
)Millisecond::per(Day)
(returnsu32
)Millisecond::per(Week)
(returnsu32
)
Trait Implementations§
Source§impl Clone for Millisecond
impl Clone for Millisecond
Source§fn clone(&self) -> Millisecond
fn clone(&self) -> Millisecond
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 Millisecond
impl Debug for Millisecond
impl Copy for Millisecond
Auto Trait Implementations§
impl Freeze for Millisecond
impl RefUnwindSafe for Millisecond
impl Send for Millisecond
impl Sync for Millisecond
impl Unpin for Millisecond
impl UnwindSafe for Millisecond
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