Trait bones_asset::prelude::bones_utils::prelude::SeededCore
pub trait SeededCore: TurboCore {
type Seed;
// Required methods
fn with_seed(seed: Self::Seed) -> Self;
fn reseed(&self, seed: Self::Seed);
}
Expand description
Trait for implementing Seedable PRNGs, requiring that the PRNG
implements TurboCore
as a baseline. Seeds must be Sized
in
order to be used as the internal state of a PRNG.
Required Associated Types§
type Seed
type Seed
Associated type for accepting valid Seed values. Must be Sized
.
Required Methods§
fn with_seed(seed: Self::Seed) -> Self
fn with_seed(seed: Self::Seed) -> Self
Creates a new SeededCore
with a specific seed value.
fn reseed(&self, seed: Self::Seed)
fn reseed(&self, seed: Self::Seed)
Reseeds the SeededCore
with a new seed/state.
Object Safety§
This trait is not object safe.