- Adopted by:
- DLRnd, DRnd
- Declared in:
- DRandomable.h
Protocol Description
The DRandomable protocol specifies methods for classes that implements
pseudo random generators.
- Last modified:
- 22-Nov-2003 (DRandomable.h)
Method Index
- - (double) nextDouble
- Get the next double from the generator (0 <= v < 1)
- Returns:
- the next double
- - (double) nextDouble :(double) from :(double) to
- Get the next double from the generator (from <= v < to)
- Parameters:
- from - the start of the range
to - the end of the range
- Returns:
- the next double
- - (int) nextInt
- Get the next integer from the generator
- Returns:
- the next integer
- - (int) nextInt :(int) from :(int) to
- Get the next integer inside a range from the generator
- Parameters:
- from - the start of the range
to - the end of the range
- Returns:
- the next integer (inside the range)
- - (long) nextLong
- Get the next long from the generator
- Returns:
- the next long
- - (long) nextLong :(long) from :(long) to
- Get the next long inside a range from the generator
- Parameters:
- from - the start of the range
to - the end of the range
- Returns:
- the next long
- - seed :(unsigned long) seed
- Set the seed for the random generator
- Parameters:
- seed - the seed for the random generator
- Returns:
- the object
generated 25-Jul-2006 by ObjcDoc 3.0.0