Complete refactor of the ReplicationValidation framework, plus the following new functionality:

* merges all pools in a lane.
 * merges all lanes in a site.
This commit is contained in:
Mauricio Carneiro 2011-07-21 21:39:00 -04:00
parent c09f92ccee
commit 8d7ef1bb51
1 changed files with 11 additions and 0 deletions

View File

@ -727,6 +727,17 @@ public class MathUtils {
return count;
}
public static <T> int countOccurrences(byte element, byte [] array) {
int count = 0;
for (byte y : array) {
if (element == y)
count++;
}
return count;
}
/**
* Returns n random indices drawn with replacement from the range 0..(k-1)
*