java.lang.Object
org.apache.jena.atlas.test.Gen
Support for testing. May be generally useful
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic int[]permute(int[] x) Pull items out of the list in a random orderstatic int[]rand(int numRand, int low, int high) Generate a random sequence between low (inclusive) and high (exclusive): may include duplicates.static int[]rand(int numRand, int low, int high, boolean allDifferent) Generate a random sequence between low (inclusive) and high (exclusive) - with duplicates or notstatic int[]shuffle(int[] x, int num) Do a number of random pair-wise swapsstatic Stringstrings(int[] keys)
-
Constructor Details
-
Gen
public Gen()
-
-
Method Details
-
rand
public static int[] rand(int numRand, int low, int high) Generate a random sequence between low (inclusive) and high (exclusive): may include duplicates. -
rand
public static int[] rand(int numRand, int low, int high, boolean allDifferent) Generate a random sequence between low (inclusive) and high (exclusive) - with duplicates or not -
permute
public static int[] permute(int[] x) Pull items out of the list in a random order -
shuffle
public static int[] shuffle(int[] x, int num) Do a number of random pair-wise swaps -
strings
-