Content deleted Content added
→Map interfaces: Add subheadings |
Add subsection |
||
Line 189:
===Map interface implementations===
Maps are data structures that associate a key with an element. This lets the map be very flexible. If the key is the hash code of the element, the <code>Map</code> is essentially a <code>Set</code>. If it's just an increasing number, it becomes a list.
Examples ====AbstractMap class====
{{java|AbstractMap }} is an example of a ''skeletal implementation''.{{sfn|Bloch|2018|loc=Chapter §4 Item 20: Prefer interfaces to abstract classes|pp=99-103}}
The direct subclasses of {{java|ConcurrentHashMap}} class include {{java|ConcurrentSkipListMap}}, {{java|EnumMap}}, {{java|HashMap}}, {{java|IdentityHashMap}}, {{java|TreeMap}} and {{java|WeakHashMap}}.
====HashMap====
|