Package java.util
Class TreeMap

Public Method get

Object get(Object key)

Overrides:

_INSERT_METHOD_SIGNATURE_HERE_

Description:

Returns the value to which this map maps the specified key. null is returned, if the map contains no mapping for this key. A return value of null dose not necessarily indicate that the map contains no mapping for this key. It's also possible that the map explicitly maps the key to null.

Example

   TreeMap treeMap = new TreeMap();
   treeMap.put("1", "T");
   treeMap.put("2", "r");
   treeMap.put("3", "e");
   treeMap.put("4", "e");
   treeMap.put("5", "M");
   treeMap.put("6", "a");
   treeMap.put("7", "p");
   Logger.log("TreeMap: " + treeMap.get("2"));

The example above returns the second element in this map.