pub trait NextRandValuewhere
Self: Sized,{
// Required methods
fn next_i64(&self) -> (i64, Self);
fn next_i32(&self) -> (i32, Self);
fn next_i16(&self) -> (i16, Self);
fn next_i8(&self) -> (i8, Self);
// Provided methods
fn next_u64(&self) -> (u64, Self) { ... }
fn next_u32(&self) -> (u32, Self) { ... }
fn next_u16(&self) -> (u16, Self) { ... }
fn next_u8(&self) -> (u8, Self) { ... }
fn next_f64(&self) -> (f64, Self) { ... }
fn next_f32(&self) -> (f32, Self) { ... }
fn next_bool(&self) -> (bool, Self) { ... }
}
Expand description
The trait to generate random values.
ランダムな値を生成するためのトレイトです。
Required Methods§
Sourcefn next_i64(&self) -> (i64, Self)
fn next_i64(&self) -> (i64, Self)
next_i64
generates a tuple of i64
and Self
.
next_i64
はi64
とSelf
のタプルを生成します。
Sourcefn next_i32(&self) -> (i32, Self)
fn next_i32(&self) -> (i32, Self)
next_i32
generates a tuple of i32
and Self
.
next_i32
はi32
とSelf
のタプルを生成します。
Provided Methods§
Sourcefn next_u64(&self) -> (u64, Self)
fn next_u64(&self) -> (u64, Self)
next_u64
generates a tuple of u64
and Self
.
next_u64
はu64
とSelf
のタプルを生成します。
Sourcefn next_u32(&self) -> (u32, Self)
fn next_u32(&self) -> (u32, Self)
next_u32
generates a tuple of u32
and Self
.
next_u32
はu32
とSelf
のタプルを生成します。
Sourcefn next_u16(&self) -> (u16, Self)
fn next_u16(&self) -> (u16, Self)
next_u16
generates a tuple of u16
and Self
.
next_u16
はu16
とSelf
のタプルを生成します。
Sourcefn next_u8(&self) -> (u8, Self)
fn next_u8(&self) -> (u8, Self)
next_u8
generates a tuple of u8
and Self
.
next_u8
はu8
とSelf
のタプルを生成します。
Sourcefn next_f64(&self) -> (f64, Self)
fn next_f64(&self) -> (f64, Self)
next_f64
generates a tuple of f64
and Self
.
next_f64
はf64
とSelf
のタプルを生成します。
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.