cmsc131Utilities
Class Random131

java.lang.Object
  extended by cmsc131Utilities.Random131

public class Random131
extends java.lang.Object

This class allows us to control the generation of random numbers.

Author:
Nelson Padua-Perez, Fawzi Emad

Constructor Summary
Random131()
           
 
Method Summary
static int getRandomInteger(int maxValue)
          Returns an integer random value between 0 and maxValue - 1 (includes 0 and maxValue - 1)
static void setDeterministic()
           
static void setDeterministic(long seed)
           
static void setNonDeterministic()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Random131

public Random131()
Method Detail

setDeterministic

public static void setDeterministic()

setDeterministic

public static void setDeterministic(long seed)

setNonDeterministic

public static void setNonDeterministic()

getRandomInteger

public static int getRandomInteger(int maxValue)
Returns an integer random value between 0 and maxValue - 1 (includes 0 and maxValue - 1)

Returns:
random integer value in the specified range


Web Accessibility