|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.drools.core.util.ConcurrentHashTable
public class ConcurrentHashTable
Constructor Summary | |
---|---|
ConcurrentHashTable(AbstractHashTable.FieldIndex[] index)
Creates a new, empty map with a default initial capacity (16), load factor (0.75) and concurrencyLevel (16). |
|
ConcurrentHashTable(AbstractHashTable.FieldIndex[] index,
int initialCapacity)
Creates a new, empty map with the specified initial capacity, and with default load factor (0.75) and concurrencyLevel (16). |
|
ConcurrentHashTable(AbstractHashTable.FieldIndex[] index,
int initialCapacity,
float loadFactor)
Creates a new, empty map with the specified initial capacity and load factor and with the default concurrencyLevel (16). |
|
ConcurrentHashTable(AbstractHashTable.FieldIndex[] index,
int initialCapacity,
float loadFactor,
int concurrencyLevel)
Creates a new, empty map with the specified initial capacity, load factor and concurrency level. |
Method Summary | |
---|---|
void |
add(RightTuple rightTuple)
|
void |
clear()
Removes all of the mappings from this map. |
RightTupleList |
get(LeftTuple tuple,
InternalFactHandle factHandle)
|
boolean |
isEmpty()
Returns true if this map contains no key-value mappings. |
void |
remove(RightTuple rightTuple)
Removes the key (and its corresponding value) from this map. |
int |
size()
Returns the number of key-value mappings in this map. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ConcurrentHashTable(AbstractHashTable.FieldIndex[] index, int initialCapacity, float loadFactor, int concurrencyLevel)
initialCapacity
- the initial capacity. The implementation
performs internal sizing to accommodate this many elements.loadFactor
- the load factor threshold, used to control resizing.
Resizing may be performed when the average number of elements per
bin exceeds this threshold.concurrencyLevel
- the estimated number of concurrently
updating threads. The implementation performs internal sizing
to try to accommodate this many threads.
IllegalArgumentException
- if the initial capacity is
negative or the load factor or concurrencyLevel are
nonpositive.public ConcurrentHashTable(AbstractHashTable.FieldIndex[] index, int initialCapacity, float loadFactor)
initialCapacity
- The implementation performs internal
sizing to accommodate this many elements.loadFactor
- the load factor threshold, used to control resizing.
Resizing may be performed when the average number of elements per
bin exceeds this threshold.
IllegalArgumentException
- if the initial capacity of
elements is negative or the load factor is nonpositivepublic ConcurrentHashTable(AbstractHashTable.FieldIndex[] index, int initialCapacity)
initialCapacity
- the initial capacity. The implementation
performs internal sizing to accommodate this many elements.
IllegalArgumentException
- if the initial capacity of
elements is negative.public ConcurrentHashTable(AbstractHashTable.FieldIndex[] index)
Method Detail |
---|
public boolean isEmpty()
public int size()
public void add(RightTuple rightTuple)
public void remove(RightTuple rightTuple)
key
- the key that needs to be removed
NullPointerException
- if the specified key is nullpublic RightTupleList get(LeftTuple tuple, InternalFactHandle factHandle)
public void clear()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |