|
||||||||||
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 java.awt.Dimension |
randomDimension()
Creates a random dimension where the height and width are between the values MINIMUM_DIMENSION and MAXIMUM_DIMENSION (inclusive). |
static java.awt.Dimension |
randomDimension(java.lang.Integer low,
java.lang.Integer high)
Creates a random dimension where the height and width are between the given values (inclusive). |
static java.lang.Integer |
randomInteger(java.lang.Integer low,
java.lang.Integer high)
Picks a random number between low and high (inclusive) |
static java.awt.Point |
randomPoint()
Creates a random dimension where the x and y coordinate are between the values MINIMUM_XY and MAXIMUM_XY (inclusive). |
static java.awt.Point |
randomPoint(java.lang.Integer low,
java.lang.Integer high)
Creates a random point where the x and y coordinates are between the given values (inclusive). |
static java.awt.Point |
randomPoint(java.lang.Integer lowX,
java.lang.Integer highX,
java.lang.Integer lowY,
java.lang.Integer highY)
Creates a random point where the x and y coordinates are between the given values (inclusive). |
static SineMaker |
randomSineMaker()
Creates a random SineMaker |
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 java.lang.Integer randomInteger(java.lang.Integer low, java.lang.Integer high)
low
- the low bound of the random numberhigh
- the high bound of the random number
public static java.awt.Dimension randomDimension(java.lang.Integer low, java.lang.Integer high)
low
- the low bound of the width and height valuehigh
- the high bound of the width and height value
public static java.awt.Dimension randomDimension()
public static java.awt.Point randomPoint()
public static java.awt.Point randomPoint(java.lang.Integer low, java.lang.Integer high)
low
- the low bound of the x and y valuehigh
- the high bound of the x and y value
public static java.awt.Point randomPoint(java.lang.Integer lowX, java.lang.Integer highX, java.lang.Integer lowY, java.lang.Integer highY)
lowX
- the low bound of the x coordinate valuehighX
- the high bound of the y coordinate valuelowY
- the low bound of y coordinate valuehighY
- the high bound of the y coordinate value
public static SineMaker randomSineMaker()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |