C# 클래스 PerplexMail.SecurityDrivenDotNet.CryptoRandom

Represents a *thread-safe*, cryptographically-strong, pseudo-random number generator (based on RNGCryptoServiceProvider). 2-4 times slower than System.Random (would've been 150 times slower without buffering).
상속: System.Random
파일 보기 프로젝트 열기: PerplexInternetmarketing/PerplexMail-for-Umbraco 1 사용 예제들

공개 메소드들

메소드 설명
Next ( ) : int

Returns a nonnegative random number.

Next ( int maxValue ) : int

Returns a nonnegative random number less than the specified maximum.

Next ( int minValue, int maxValue ) : int

Returns a random number within a specified range.

NextBytes ( byte buffer ) : void

Fills the elements of a specified array of bytes with random numbers.

NextDouble ( ) : double

Returns a random number between 0.0 and 1.0.

NextLong ( ) : long

Returns a nonnegative random number.

NextLong ( long maxValue ) : long

Returns a nonnegative random number less than the specified maximum.

NextLong ( long minValue, long maxValue ) : long

Returns a random number within a specified range.

비공개 메소드들

메소드 설명
GetRandomUInt ( ) : uint

Gets one random unsigned 32bit integer in a thread safe manner.

GetRandomULong ( ) : ulong

Gets one random unsigned 64bit integer in a thread safe manner.

메소드 상세

Next() 공개 메소드

Returns a nonnegative random number.
public Next ( ) : int
리턴 int

Next() 공개 메소드

Returns a nonnegative random number less than the specified maximum.
/// is less than zero. ///
public Next ( int maxValue ) : int
maxValue int The exclusive upper bound of the random number to be generated. must be greater than or equal to zero.
리턴 int

Next() 공개 메소드

Returns a random number within a specified range.
/// is greater than . ///
public Next ( int minValue, int maxValue ) : int
minValue int The inclusive lower bound of the random number returned.
maxValue int The exclusive upper bound of the random number returned. must be greater than or equal to .
리턴 int

NextBytes() 공개 메소드

Fills the elements of a specified array of bytes with random numbers.
/// is null. ///
public NextBytes ( byte buffer ) : void
buffer byte An array of bytes to contain random numbers.
리턴 void

NextDouble() 공개 메소드

Returns a random number between 0.0 and 1.0.
public NextDouble ( ) : double
리턴 double

NextLong() 공개 메소드

Returns a nonnegative random number.
public NextLong ( ) : long
리턴 long

NextLong() 공개 메소드

Returns a nonnegative random number less than the specified maximum.
/// is less than zero. ///
public NextLong ( long maxValue ) : long
maxValue long The exclusive upper bound of the random number to be generated. must be greater than or equal to zero.
리턴 long

NextLong() 공개 메소드

Returns a random number within a specified range.
/// is greater than . ///
public NextLong ( long minValue, long maxValue ) : long
minValue long The inclusive lower bound of the random number returned.
maxValue long The exclusive upper bound of the random number returned. must be greater than or equal to .
리턴 long