pub struct VirtualTime(/* private fields */);Expand description
The current time of a virtual clock, shared between the host and whoever moves it.
Cloning shares the same counter: advancing one handle advances every clone,
including the one already given to a Clock. The counter is
synchronized because a host is reachable from every task of a run, so two
tasks may read or advance this clock at the same time.
Implementations§
Source§impl VirtualTime
impl VirtualTime
Trait Implementations§
Source§impl Clone for VirtualTime
impl Clone for VirtualTime
Source§fn clone(&self) -> VirtualTime
fn clone(&self) -> VirtualTime
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 VirtualTime
impl Debug for VirtualTime
Source§impl Default for VirtualTime
impl Default for VirtualTime
Source§fn default() -> VirtualTime
fn default() -> VirtualTime
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for VirtualTime
impl RefUnwindSafe for VirtualTime
impl Send for VirtualTime
impl Sync for VirtualTime
impl Unpin for VirtualTime
impl UnsafeUnpin for VirtualTime
impl UnwindSafe for VirtualTime
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