| Package | Description |
|---|---|
| net.lecousin.framework.collections.map |
Implementations of Maps.
|
| Modifier and Type | Interface and Description |
|---|---|
interface |
ByteMap<ValueType>
Interface for a Map that accept byte keys (primitive type instead of Byte).
|
interface |
IntegerMap<ValueType>
Interface for a Map that accept int keys (primitive type instead of Integer).
|
interface |
LongMap<ValueType>
Interface for a Map that accept long keys (primitive type instead of Long).
|
interface |
ShortMap<ValueType>
Interface for a Map that accept short keys (primitive type instead of Short).
|
| Modifier and Type | Class and Description |
|---|---|
class |
HalfByteHashMap<T>
This class uses the 4 lower bits of a byte as a hash code, then for each hash code
associates an ordered array.
In other words, it splits bytes over 16 buckets, each bucket containing up to 16 key-value pairs. The insert and remove operations are costly because we need to reallocate and order the arrays, but the get operation is fast, while using reasonable amount of memory. |
class |
IntegerMapLinkedArrayList<T>
Implementation of an IntegerMap, with a specified number of buckets, each bucket being associated with a LinkedArrayList.
|
class |
IntegerMapRBT<T>
Implements an IntegerMap, with a fixed number of buckets, each bucket containing a Red-Black tree to order elements and find them quickly.
The hash method uses by default a modulus operation, but may be overridden if needed. |
class |
LongMapRBT<T>
Implements a LongMap, with a fixed number of buckets, each bucket containing a Red-Black tree to order elements and find them quickly.
The hash method uses by default a modulus operation, but may be overridden if needed. |
Copyright © 2019. All rights reserved.