C# Class Binarysharp.MemoryManagement.Helpers.Randomizer

Static helper class providing tools for generating random numbers or strings.
Datei anzeigen Open project: ZenLulz/MemorySharp

Public Methods

Method Description
GenerateGuid ( ) : System.Guid

Initializes a new instance of the Guid structure.

GenerateNumber ( ) : int

Returns a nonnegative random number.

GenerateNumber ( int maxValue ) : int

Returns a nonnegative random number less than the specified maximum.

GenerateNumber ( int minValue, int maxValue ) : int

Returns a random number within a specified range.

GenerateString ( int minSize = 40, int maxSize = 40 ) : string

Returns a random string where its size is within a specified range.

Method Details

GenerateGuid() public static method

Initializes a new instance of the Guid structure.
public static GenerateGuid ( ) : System.Guid
return System.Guid

GenerateNumber() public static method

Returns a nonnegative random number.
public static GenerateNumber ( ) : int
return int

GenerateNumber() public static method

Returns a nonnegative random number less than the specified maximum.
public static GenerateNumber ( int maxValue ) : int
maxValue int The exclusive upper bound of the random number to be generated. maxValue must be greater than or equal to zero.
return int

GenerateNumber() public static method

Returns a random number within a specified range.
public static GenerateNumber ( 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. maxValue must be greater than or equal to minValue.
return int

GenerateString() public static method

Returns a random string where its size is within a specified range.
public static GenerateString ( int minSize = 40, int maxSize = 40 ) : string
minSize int The inclusive lower bound of the size of the string returned.
maxSize int The exclusive upper bound of the size of the string returned.
return string