Map implemented by HashMap and TreeMap
Tutorial Details:
Map.Entry which describes access methods to the key-value pairs.
Implementing classes
A number of classes implement the Map interface, including HashMap, TreeMap, LinkedHashMap, WeakHashMap, ConcurrentHashMap, and Properties. The most generally useful class is HashMap.
java.util.HashMap is implemented with a hash table. Access time is O(1). Entries are unsorted.
java.util.LinkedHashMap is implemented with a hash table. Access time is O(1). Entries are sorted in either entry order or order of last access, which is useful for implementing a LRU (least recently used) caching policy.
Rate Tutorial: http://www.roseindia.net/java/java-tips/data/collections_non_generic/30maps/20map_interface.shtml
Read
Tutorial at: Click here to view the tutorial
Rate Tutorial: Java: Maps
View Tutorial: Java: Maps
Related
Tutorials:
|