pub struct SimulationContext { /* private fields */ }Implementations§
Source§impl SimulationContext
impl SimulationContext
pub fn new(seed: u64) -> Self
pub fn with_buggify_ppm(seed: u64, buggify_ppm: u64) -> Self
Sourcepub fn with_fault_class(self, class: FaultClass, ppm: u64) -> Self
pub fn with_fault_class(self, class: FaultClass, ppm: u64) -> Self
Arm one named fault class at ppm. 0 leaves it off (the default).
Sourcepub fn fault_ppm(&self, class: FaultClass) -> u64
pub fn fault_ppm(&self, class: FaultClass) -> u64
The probability currently armed for class.
pub fn install(self) -> SimulationGuard
Trait Implementations§
Source§impl Clone for SimulationContext
impl Clone for SimulationContext
Source§fn clone(&self) -> SimulationContext
fn clone(&self) -> SimulationContext
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 moreimpl Copy for SimulationContext
Auto Trait Implementations§
impl Freeze for SimulationContext
impl RefUnwindSafe for SimulationContext
impl Send for SimulationContext
impl Sync for SimulationContext
impl Unpin for SimulationContext
impl UnsafeUnpin for SimulationContext
impl UnwindSafe for SimulationContext
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