code: public static HashMap merge(Map map1, Map map2)
      {
          HashMap retval = new HashMap(calcCapacity(map1.size() + map2.size()));
  
          retval.putAll(map1);
          retval.putAll(map2);
  
          return retval;
      }
docs: Creates a new <code>HashMap</code> that has all of the elements
  of <code>map1</code> and <code>map2</code> (on key collision, the latter
  override the former).
  
  @param map1 the fist hashmap to merge
  @param map2 the second hashmap to merge
  @return new hashmap