Wednesday, April 20, 2011

Create Weak Multimap with Google Collections

Is there an equivalent to the nice MapMaker for MultiMaps? currently i create the cache like this:

    public static Map<Session,List<Person>> personCache = new MapMaker().weakKeys().makeMap();

the whole point of MultiMap is to avoid the nested List Values. is there any way to construct the multimap with weak keys?

From stackoverflow
  • Unfortunately not. Yet. Could you file a MultimapMaker feature request in our issues db? http://google-collections.googlecode.com

    Andreas Petersson : done. http://code.google.com/p/google-collections/issues/detail?id=142

0 comments:

Post a Comment