com.liferay.portal.kernel.test.util
Class RandomTestUtil
java.lang.Object
com.liferay.portal.kernel.test.util.RandomTestUtil
public class RandomTestUtil
- extends Object
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RandomTestUtil
public RandomTestUtil()
nextDate
public static Date nextDate()
nextDouble
public static double nextDouble()
throws Exception
- Throws:
Exception
nextInt
public static int nextInt()
throws Exception
- Throws:
Exception
nextLong
public static long nextLong()
throws Exception
- Throws:
Exception
randomBoolean
public static boolean randomBoolean()
randomBytes
@SafeVarargs
public static byte[] randomBytes(int size,
RandomizerBumper<byte[]>... randomizerBumpers)
randomBytes
@SafeVarargs
public static byte[] randomBytes(RandomizerBumper<byte[]>... randomizerBumpers)
randomDouble
public static double randomDouble()
randomInputStream
@SafeVarargs
public static InputStream randomInputStream(RandomizerBumper<byte[]>... randomizerBumpers)
randomInt
public static int randomInt()
randomInt
public static int randomInt(int min,
int max)
throws IllegalArgumentException
- Throws:
IllegalArgumentException
randomLocaleStringMap
public static Map<Locale,String> randomLocaleStringMap()
randomLocaleStringMap
public static Map<Locale,String> randomLocaleStringMap(Locale locale)
randomLong
public static long randomLong()
randomString
@SafeVarargs
public static String randomString(int length,
RandomizerBumper<String>... randomizerBumpers)
randomString
@SafeVarargs
public static String randomString(RandomizerBumper<String>... randomizerBumpers)
randomStrings
@SafeVarargs
public static String[] randomStrings(int count,
RandomizerBumper<String>... randomizerBumpers)
randomUnicodeProperties
public static UnicodeProperties randomUnicodeProperties(int propertyCount,
int keyLength,
int valueLength)