Class SentinelIntSet
- java.lang.Object
-
- org.apache.lucene.search.grouping.SentinelIntSet
-
public class SentinelIntSet extends Object
A native int set where one value is reserved to mean "EMPTY"- NOTE: This API is for internal purposes only and might change in incompatible ways in the next release.
-
-
Field Summary
Fields Modifier and Type Field Description intcountintemptyValint[]keysintrehashCount
-
Constructor Summary
Constructors Constructor Description SentinelIntSet(int size, int emptyVal)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclear()booleanexists(int key)intfind(int key)returns the slot for this key, or -slot-1 if not foundintgetSlot(int key)returns the slot for this keyinthash(int key)intput(int key)voidrehash()intsize()
-
-
-
Method Detail
-
clear
public void clear()
-
hash
public int hash(int key)
-
size
public int size()
-
getSlot
public int getSlot(int key)
returns the slot for this key
-
find
public int find(int key)
returns the slot for this key, or -slot-1 if not found
-
exists
public boolean exists(int key)
-
put
public int put(int key)
-
rehash
public void rehash()
-
-