guava/src/com/google/common/collect/HashBiMap.java
public static <K, V> HashBiMap<K, V> create(Map<? extends K, ? extends V> map) {
    HashBiMap<K, V> bimap = create(map.size());
    bimap.putAll(map);
    return bimap;
  }
public static <K, V> HashBiMap<K, V> create(Map<? extends K, ? extends V> map) {
    HashBiMap<K, V> bimap = create(map.size());
    bimap.putAll(map);
    return bimap;
  }
public static < K , V > HashBiMap < K , V > create ( Map < ? extends K , ? extends V > map ) { HashBiMap < K , V > bimap = create ( map . size ( ) ) ; bimap . putAll ( map ) ; return bimap ; }
Constructs a new bimap containing initial values from {@code map}. The bimap is created with an
initial capacity sufficient to hold the mappings in the specified map.
Constructs a new bimap containing initial values from {