public final class RandomUtils extends Object
RandomStringUtils| 构造器和说明 |
|---|
RandomUtils()
私有构造方法
|
| 限定符和类型 | 方法和说明 |
|---|---|
static boolean |
nextBoolean()
随机生成布尔值
|
static byte[] |
nextBytes(int count)
随机生成字节数组
|
static double |
nextDouble()
随机生成双精度数
|
static double |
nextDouble(double startInclusive,
double endExclusive)
随机生成双精度数
|
static float |
nextFloat()
随机生成浮点数数
|
static float |
nextFloat(float startInclusive,
float endExclusive)
随机生成浮点数数
|
static int |
nextInt()
随机生成整数
|
static int |
nextInt(int startInclusive,
int endExclusive)
随机生成整数
|
static long |
nextLong()
随机生成长整数
|
static long |
nextLong(long startInclusive,
long endExclusive)
随机生成长整数
|
public static boolean nextBoolean()
public static byte[] nextBytes(int count)
count - 字符数组长度public static int nextInt(int startInclusive,
int endExclusive)
startInclusive - 开始 (包含)endExclusive - 结束 (不包含)public static int nextInt()
public static long nextLong(long startInclusive,
long endExclusive)
startInclusive - 开始 (包含)endExclusive - 结束 (不包含)public static long nextLong()
public static double nextDouble(double startInclusive,
double endExclusive)
startInclusive - 开始 (包含)endExclusive - 结束 (不包含)public static double nextDouble()
public static float nextFloat(float startInclusive,
float endExclusive)
startInclusive - 开始 (包含)endExclusive - 结束 (不包含)public static float nextFloat()
Copyright © 2022. All rights reserved.