pub trait VmiHandlerExt<Os>: VmiHandler<Os> + Sizedwhere
Os: VmiOs,{
// Provided methods
fn with_deadline(self, deadline: Instant) -> VmiTerminationHandler<Self> { ... }
fn with_termination_flag(
self,
termination_flag: Arc<AtomicBool>,
) -> VmiTerminationHandler<Self> { ... }
fn with_termination_timeout(
self,
termination_timeout: Duration,
) -> VmiTerminationHandler<Self> { ... }
}Expand description
Extension methods on VmiHandler.
The blanket impl is the only impl of this trait, so implementors of
VmiHandler cannot override the default bodies.
Provided Methods§
Sourcefn with_deadline(self, deadline: Instant) -> VmiTerminationHandler<Self>
fn with_deadline(self, deadline: Instant) -> VmiTerminationHandler<Self>
Wraps the handler in a VmiTerminationHandler that interrupts it
at deadline.
Sourcefn with_termination_flag(
self,
termination_flag: Arc<AtomicBool>,
) -> VmiTerminationHandler<Self>
fn with_termination_flag( self, termination_flag: Arc<AtomicBool>, ) -> VmiTerminationHandler<Self>
Wraps the handler in a VmiTerminationHandler with a flag that
interrupts it once the flag becomes true.
Sourcefn with_termination_timeout(
self,
termination_timeout: Duration,
) -> VmiTerminationHandler<Self>
fn with_termination_timeout( self, termination_timeout: Duration, ) -> VmiTerminationHandler<Self>
Wraps the handler in a VmiTerminationHandler that gives it
termination_timeout to finish once interrupted.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".