pub enum RandomStart {
System,
CallHost,
Seed(RandomSeed),
}Expand description
Where an unseeded random generator gets its first state.
Variants§
System
From the sandbox’s own OS entropy.
CallHost
Request one state vector (2496 bytes) from the host via os.urandom on the first draw.
Seed(RandomSeed)
The module-level generator starts exactly as random.seed(seed) leaves
it; unseeded random.Random() instances take deterministic states
derived from the same seed.
Trait Implementations§
Source§impl Clone for RandomStart
impl Clone for RandomStart
Source§impl Debug for RandomStart
impl Debug for RandomStart
Source§impl Default for RandomStart
impl Default for RandomStart
Source§impl<'de> Deserialize<'de> for RandomStart
impl<'de> Deserialize<'de> for RandomStart
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for RandomStart
impl PartialEq for RandomStart
Source§impl Serialize for RandomStart
impl Serialize for RandomStart
impl StructuralPartialEq for RandomStart
Auto Trait Implementations§
impl Freeze for RandomStart
impl RefUnwindSafe for RandomStart
impl Send for RandomStart
impl Sync for RandomStart
impl Unpin for RandomStart
impl UnsafeUnpin for RandomStart
impl UnwindSafe for RandomStart
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