src/main/java/org/jivesoftware/smack/util/collections/AbstractHashedMap.java
public void putAll(Map<? extends K, ? extends V> map) {
        int mapSize = map.size();
        if (mapSize == 0) {
            return;
        }
        int newSize = (int) ((size + mapSize) / loadFactor + 1);
        ensureCapacity(calculateNewCapacity(newSize));
        // Have to cast here because of compiler inference problems.
        for (Iterator it = map.entrySet().iterator(); it.hasNext();) {
            Map.Entry<? extends K, ? extends V> entry = (Map.Entry<? extends K, ? extends V>) it
                    .next();
            put(entry.getKey(), entry.getValue());
        }
    }
public void putAll(Map<? extends K, ? extends V> map) {
        int mapSize = map.size();
        if (mapSize == 0) {
            return;
        }
        int newSize = (int) ((size + mapSize) / loadFactor + 1);
        ensureCapacity(calculateNewCapacity(newSize));
        // Have to cast here because of compiler inference problems.
        for (Iterator it = map.entrySet().iterator(); it.hasNext();) {
            Map.Entry<? extends K, ? extends V> entry = (Map.Entry<? extends K, ? extends V>) it
                    .next();
            put(entry.getKey(), entry.getValue());
        }
    }
Puts all the values from the specified map into this map.
<p/>
This implementation iterates around the specified map and uses
{@link #put(Object, Object)}.

@param map
the map to add
@throws NullPointerException
if the map is null