|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object utilities.Random
public class Random
A class that contains many useful methods for finding random values of different classes.
Constructor Summary | |
---|---|
Random()
|
Method Summary | |
---|---|
static Color |
randomColor()
Creates a random color |
static Dimension |
randomDimension()
Creates a random dimension where the height and width are between the values MINIMUM_DIMENSION and MAXIMUM_DIMENSION (inclusive). |
static Dimension |
randomDimension(Integer low,
Integer high)
Creates a random dimension where the height and width are between the given values (inclusive). |
static Integer |
randomInteger(Integer low,
Integer high)
Picks a random number between low and high (inclusive) |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Random()
Method Detail |
---|
public static Color randomColor()
graphics.colors.Color
public static Integer randomInteger(Integer low, Integer high)
low
- the low bound of the random numberhigh
- the high bound of the random number
public static Dimension randomDimension(Integer low, Integer high)
low
- the low bound of the width and height valuehigh
- the high bound of the width and height value
public static Dimension randomDimension()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |