Pseudo-random number generator. More...
Static Public Member Functions | |
| static unsigned int | getNext () |
| static unsigned int | getTime () |
| static unsigned int | getProcess () |
| static const string | getString (const int length, const string &randomChars="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789") |
Static Protected Attributes | |
| static unsigned int | m_next |
Pseudo-random number generator.
| unsigned int getNext | ( | ) | [static] |
Return a new random number.
References random::m_next.
Referenced by body::generateRandomBoundaryString(), and random::getString().
| unsigned int getProcess | ( | ) | [static] |
Return the current process number (may be user to build "random" strings).
References platform::getHandler().
| const string getString | ( | const int | length, | |
| const string & | randomChars = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789" | |||
| ) | [static] |
Return a random character string with the specified length.
| length | length of the string to generate | |
| randomChars | list of characters to use |
References random::getNext().
| unsigned int getTime | ( | ) | [static] |
Return the current time as a number (may be used to build "random" strings).
References platform::getHandler().
Referenced by body::generateRandomBoundaryString().
unsigned int m_next [static, protected] |
Referenced by random::getNext().
1.6.2