|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.blogspot.applications4android.comicreader.core.RandUtils
public class RandUtils
Utilities class for generating random numbers
Method Summary | |
---|---|
static RandUtils |
getObj()
Gets the object of this class |
static int |
getPositiveInt()
Generate a positive random integer |
static int |
getPositiveInt(int limit)
Generate a positive random integer |
static int |
getPositiveInt(int limit,
int first)
Generate a positive random integer |
static long |
getPositiveLong()
Generate a positive random long integer |
static long |
getPositiveLong(long limit)
Generate a positive random long integer |
static long |
getPositiveLong(long limit,
long first)
Generate a positive random long integer |
static java.util.Random |
getRNG()
Gets the RNG for this class |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static RandUtils getObj()
public static java.util.Random getRNG()
public static int getPositiveInt()
public static int getPositiveInt(int limit)
limit
- numbers should be between 0 to limit-1
public static int getPositiveInt(int limit, int first)
limit
- numbers should be between 0 to limit-1first
- the first number in the range first to first + limit - 1
public static long getPositiveLong()
public static long getPositiveLong(long limit)
limit
- numbers should be between 0 to limit-1
public static long getPositiveLong(long limit, long first)
limit
- numbers should be between 0 to limit-1first
- the first number in the range first to first + limit - 1
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |