SmallRng Class
A non-cryptographically secure RNG with good performance and output quality, while requiring limited memory.
Namespace
RandN
Interfaces
Base Types
  • object
SmallRng
object
IRng

Syntax

public sealed class SmallRng : IRng

Methods

NameReturn ValueSummary
Create()SmallRng
Creates a StandardRng.
static
Fill(Span<byte>)void
Completely fills the span with random bytes.
GetFactory()SmallRng.Factory
Gets the StandardRng factory.
static
NextUInt32()uint
Returns the next 32 bits in the sequence as a UInt32.
NextUInt64()ulong
Returns the next 64 bits in the sequence as a UInt64.

Extension Methods

NameValueSummary
Sample<SmallRng, TDistribution, TResult>(TDistribution)TResult
Samples the distribution from rng.
Sample<SmallRng, TResult>(IDistribution<TResult>)TResult
Samples the distribution from rng.
ShuffleInPlace<SmallRng, T>(IList<T>)void
Shuffles a list using the in-place Fisher-Yates shuffling algorithm.