Package java.util
Class TreeMap

Public Method putAll

void putAll(Map map)

Overrides:

_INSERT_METHOD_SIGNATURE_HERE_

Description:

Copies all of the mapping from the specified map to this map. These mappings replace any mappings that this map had for any of this keys currently in the specified map.

Example

   TreeMap treeMap1 = new TreeMap();
   treeMap1.put("1", "T");
   treeMap1.put("2", "r");
   treeMap1.put("3", "e");
   treeMap1.put("4", "e");
   treeMap1.put("5", "M");
   treeMap1.put("6", "a");
   treeMap1.put("7", "p");

   TreeMap treeMap2 = new TreeMap();
   treeMap2.putAll(treeMap1);
   Logger.log("treeMap1: " + treeMap1);
   Logger.log("treeMap2: " + treeMap2);

The example above puts all the elements with the according keys from the treeMap1 into the treeMap2.