V - value type of mappingpublic final class FastByIDMap<V> extends Object implements Serializable, Cloneable
FastByIDMap; adds new methods.| Modifier and Type | Class and Description |
|---|---|
static interface |
FastByIDMap.MapEntry<V> |
| Modifier and Type | Field and Description |
|---|---|
static int |
NO_MAX_SIZE |
| Constructor and Description |
|---|
FastByIDMap()
Creates a new with default capacity.
|
FastByIDMap(int size) |
FastByIDMap(int size,
float loadFactor) |
FastByIDMap(int size,
int maxSize) |
FastByIDMap(int size,
int maxSize,
float loadFactor)
Creates a new whose capacity can accommodate the given number of entries without
rehash.
|
| Modifier and Type | Method and Description |
|---|---|
void |
clear() |
FastByIDMap<V> |
clone() |
boolean |
containsKey(long key) |
boolean |
containsValue(Object value) |
Set<FastByIDMap.MapEntry<V>> |
entrySet() |
boolean |
equals(Object other) |
V |
get(long key) |
int |
hashCode() |
boolean |
isEmpty() |
org.apache.mahout.cf.taste.impl.common.LongPrimitiveIterator |
keySetIterator() |
V |
put(long key,
V value) |
void |
rehash() |
V |
remove(long key) |
int |
size() |
String |
toString() |
Collection<V> |
values() |
public static final int NO_MAX_SIZE
public FastByIDMap()
public FastByIDMap(int size)
public FastByIDMap(int size,
float loadFactor)
public FastByIDMap(int size,
int maxSize)
public FastByIDMap(int size,
int maxSize,
float loadFactor)
size - desired capacitymaxSize - max capacityloadFactor - ratio of internal hash table size to current sizeIllegalArgumentException - if size is less than 0, maxSize is less than 1
or at least half of RandomUtils.MAX_INT_SMALLER_TWIN_PRIME, or
loadFactor is less than 1public V get(long key)
public int size()
public boolean isEmpty()
public boolean containsKey(long key)
public boolean containsValue(Object value)
public V remove(long key)
public void clear()
public org.apache.mahout.cf.taste.impl.common.LongPrimitiveIterator keySetIterator()
public Set<FastByIDMap.MapEntry<V>> entrySet()
public Collection<V> values()
public void rehash()
public FastByIDMap<V> clone()
Copyright © 2012-2013 Myrrix Ltd. All Rights Reserved.