How to create a Multimap<K,V> from a Map<K, Collection<V>>?
问题 I didn't find such a multimap construction... When I want to do this, I iterate over the map, and populate the multimap. Is there an other way? final Map<String, Collection<String>> map = ImmutableMap.<String, Collection<String>>of( "1", Arrays.asList("a", "b", "c", "c")); System.out.println(Multimaps.forMap(map)); final Multimap<String, String> expected = ArrayListMultimap.create(); for (Map.Entry<String, Collection<String>> entry : map.entrySet()) { expected.putAll(entry.getKey(), entry