NamespaceSystemLibrary.Common.Framework SystemLibrary.Common.Framework.Net.dll
Shortcut for generating random values using System.Random
Randomness
public static class Randomness
Inheritance
object
Randomness
Examples
Arguments
X
Methods
Generate a random Byte array
public static byte[] Bytes(int length = 16)
X
Methods arguments
Type | Name | Description |
---|---|---|
int | length |
X
Type | Description |
---|---|
byte[] | Byte array filled with random int's |
Generate a random Integer
public static int Int(int maxValue = 2147483647)
X
Methods arguments
Type | Name | Description |
---|---|---|
int | maxValue |
X
Type | Description |
---|---|
int | Integer >= 0 |
Generate a random Integer
public static int Int(int minValue, int maxValue)
X
Methods arguments
Type | Name | Description |
---|---|---|
int | minValue | |
int | maxValue |
X
Type | Description |
---|---|
int | Integer >= 0 |
Generate a random string
public static string String(int length = 6)
X
Methods arguments
Type | Name | Description |
---|---|---|
int | length |
X
Type | Description |
---|---|
string | Returns a string of length |
}