public static class IntPerfectHash.BitArray
extends java.lang.Object
| Constructor and Description |
|---|
BitArray() |
| Modifier and Type | Method and Description |
|---|---|
static int |
countBits(byte[] data)
Count the number of set bits.
|
static boolean |
getBit(byte[] data,
int x)
Get a bit in a bit array.
|
static byte[] |
setBit(byte[] data,
int x,
boolean value)
Set a bit in the array.
|
public static byte[] setBit(byte[] data,
int x,
boolean value)
data - the arrayx - the bit indexvalue - the new valuepublic static boolean getBit(byte[] data,
int x)
data - the arrayx - the bit indexpublic static int countBits(byte[] data)
data - the array