|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.ardverk.collection.AbstractKeyAnalyzer<char[]>
org.ardverk.collection.CharArrayKeyAnalyzer
public class CharArrayKeyAnalyzer
An KeyAnalyzer
for char[]
s
Field Summary | |
---|---|
static CharArrayKeyAnalyzer |
INSTANCE
A singleton instance of CharArrayKeyAnalyzer |
static int |
LENGTH
The number of bits per Character |
Fields inherited from interface org.ardverk.collection.KeyAnalyzer |
---|
EQUAL_BIT_KEY, NULL_BIT_KEY, OUT_OF_BOUNDS_BIT_KEY |
Constructor Summary | |
---|---|
CharArrayKeyAnalyzer()
|
Method Summary | |
---|---|
int |
bitIndex(char[] key,
int offsetInBits,
int lengthInBits,
char[] other,
int otherOffsetInBits,
int otherLengthInBits)
Returns the n-th different bit between key and found. |
int |
bitsPerElement()
Returns the number of bits per element in the key. |
boolean |
isBitSet(char[] key,
int bitIndex,
int lengthInBits)
Returns whether or not a bit is set |
boolean |
isPrefix(char[] prefix,
int offsetInBits,
int lengthInBits,
char[] key)
Determines whether or not the given prefix (from offset to length) is a prefix of the given key. |
int |
lengthInBits(char[] key)
Returns the length of the Key in bits. |
Methods inherited from class org.ardverk.collection.AbstractKeyAnalyzer |
---|
compare |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface java.util.Comparator |
---|
equals |
Field Detail |
---|
public static final CharArrayKeyAnalyzer INSTANCE
CharArrayKeyAnalyzer
public static final int LENGTH
Character
Constructor Detail |
---|
public CharArrayKeyAnalyzer()
Method Detail |
---|
public int bitsPerElement()
public int lengthInBits(char[] key)
public int bitIndex(char[] key, int offsetInBits, int lengthInBits, char[] other, int otherOffsetInBits, int otherLengthInBits)
public boolean isBitSet(char[] key, int bitIndex, int lengthInBits)
public boolean isPrefix(char[] prefix, int offsetInBits, int lengthInBits, char[] key)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |