| Package | Description |
|---|---|
| java.util |
| Modifier and Type | Interface and Description |
|---|---|
interface |
SortedMap<K,V>
A
Map that further provides a total ordering on its keys. |
| Modifier and Type | Class and Description |
|---|---|
class |
AbstractMap<K,V>
This class provides a skeletal implementation of the Map
interface, to minimize the effort required to implement this interface.
|
class |
HashMap<K,V>
Hash table based implementation of the Map interface.
|
class |
Hashtable<K,V>
This class implements a hash table, which maps keys to values.
|
class |
LinkedHashMap<K,V>
Hash table and linked list implementation of the Map interface,
with predictable iteration order.
|
| Modifier and Type | Field and Description |
|---|---|
static Map |
Collections.EMPTY_MAP
The empty map (immutable).
|
| Modifier and Type | Method and Description |
|---|---|
static <K,V> Map<K,V> |
Collections.checkedMap(Map<K,V> m,
Class<K> keyType,
Class<V> valueType)
Returns a dynamically typesafe view of the specified map.
|
static <K,V> Map<K,V> |
Collections.emptyMap()
Returns the empty map (immutable).
|
static <K,V> Map<K,V> |
Collections.singletonMap(K key,
V value)
Returns an immutable map, mapping only the specified key to the
specified value.
|
static <K,V> Map<K,V> |
Collections.synchronizedMap(Map<K,V> m)
Returns a synchronized (thread-safe) map backed by the specified
map.
|
static <K,V> Map<K,V> |
Collections.unmodifiableMap(Map<? extends K,? extends V> m)
Returns an unmodifiable view of the specified map.
|
| Modifier and Type | Method and Description |
|---|---|
static <K,V> Map<K,V> |
Collections.checkedMap(Map<K,V> m,
Class<K> keyType,
Class<V> valueType)
Returns a dynamically typesafe view of the specified map.
|
static <E> Set<E> |
Collections.newSetFromMap(Map<E,Boolean> map)
Returns a set backed by the specified map.
|
void |
Map.putAll(Map<? extends K,? extends V> m)
Copies all of the mappings from the specified map to this map
(optional operation).
|
void |
Hashtable.putAll(Map<? extends K,? extends V> t)
Copies all of the mappings from the specified map to this hashtable.
|
void |
HashMap.putAll(Map<? extends K,? extends V> m)
Copies all of the mappings from the specified map to this map.
|
void |
AbstractMap.putAll(Map<? extends K,? extends V> m)
Copies all of the mappings from the specified map to this map
(optional operation).
|
static <K,V> Map<K,V> |
Collections.synchronizedMap(Map<K,V> m)
Returns a synchronized (thread-safe) map backed by the specified
map.
|
static <K,V> Map<K,V> |
Collections.unmodifiableMap(Map<? extends K,? extends V> m)
Returns an unmodifiable view of the specified map.
|
| Constructor and Description |
|---|
HashMap(Map<? extends K,? extends V> m)
Constructs a new HashMap with the same mappings as the
specified Map.
|
Hashtable(Map<? extends K,? extends V> t)
Constructs a new hashtable with the same mappings as the given
Map.
|
LinkedHashMap(Map<? extends K,? extends V> m)
Constructs an insertion-ordered LinkedHashMap instance with
the same mappings as the specified map.
|
Copyright © 2013 API Design. All Rights Reserved.