Here you can find the source of map(Map.Entry
public static <K, V> Map<K, V> map(Map.Entry<K, V>... entries)
//package com.java2s; //License from project: Apache License import java.util.*; public class Main { public static <K, V> Map<K, V> map(Map.Entry<K, V>... entries) { HashMap<K, V> resultMap = new HashMap<K, V>(entries.length); for (Map.Entry<K, V> mapEntry : entries) { resultMap.put(mapEntry.getKey(), mapEntry.getValue()); }//w w w.j a v a 2s . c o m return resultMap; } }