pub struct DurationGenerator { /* private fields */ }Expand description
Generator for creating Duration values with a specified strategy.
Created from a DurationGenerationMode to enable consistent duration
generation across multiple calls.
Implementations§
Source§impl DurationGenerator
impl DurationGenerator
Sourcepub fn new(mode: DurationGenerationMode) -> Self
pub fn new(mode: DurationGenerationMode) -> Self
Create a new Duration generator with the specified mode.
Sourcepub fn mode(&self) -> DurationGenerationMode
pub fn mode(&self) -> DurationGenerationMode
Get the generation mode.
Trait Implementations§
Source§impl Clone for DurationGenerator
impl Clone for DurationGenerator
Source§fn clone(&self) -> DurationGenerator
fn clone(&self) -> DurationGenerator
Returns a duplicate 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 DurationGenerator
impl Debug for DurationGenerator
Source§impl Generator for DurationGenerator
impl Generator for DurationGenerator
impl Copy for DurationGenerator
Auto Trait Implementations§
impl Freeze for DurationGenerator
impl RefUnwindSafe for DurationGenerator
impl Send for DurationGenerator
impl Sync for DurationGenerator
impl Unpin for DurationGenerator
impl UnwindSafe for DurationGenerator
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