Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #6293

Re: Generics for a multiplevalue hashmap

Path csiph.com!x330-a1.tempe.blueboxinc.net!newsfeed.hal-mli.net!feeder3.hal-mli.net!news.glorb.com!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail
From Richard <iamrichardjones@gmail.com>
Newsgroups comp.lang.java.programmer
Subject Re: Generics for a multiplevalue hashmap
Date Tue, 19 Jul 2011 13:32:28 -0700 (PDT)
Organization http://groups.google.com
Lines 16
Message-ID <295b693a-1ba9-454f-965b-d33fc4d43731@glegroupsg2000goo.googlegroups.com> (permalink)
Reply-To comp.lang.java.programmer@googlegroups.com
NNTP-Posting-Host 86.30.253.4
Mime-Version 1.0
Content-Type text/plain; charset=ISO-8859-1
X-Trace posting.google.com 1311107549 10596 127.0.0.1 (19 Jul 2011 20:32:29 GMT)
X-Complaints-To groups-abuse@google.com
NNTP-Posting-Date Tue, 19 Jul 2011 20:32:29 +0000 (UTC)
In-Reply-To <multimap-20110719190334@ram.dialup.fu-berlin.de>
Complaints-To groups-abuse@google.com
Injection-Info glegroupsg2000goo.googlegroups.com; posting-host=86.30.253.4; posting-account=v0qi1QoAAAAVAvWRFn4efQKvN8i9z5Sv
User-Agent G2/1.0
X-Google-Web-Client true
Xref x330-a1.tempe.blueboxinc.net comp.lang.java.programmer:6293

Show key headers only | View raw


Thanks for all your replies.

I have done this

public class MultipleValueHashMap<T, U>  implements Map<T, java.util.List<U>> {

I want to implement Map rather than extend HashMap as per Josh Bloch's Effective Java item 16. http://java.sun.com/docs/books/effective/toc.html

So I do not want to do this.
public class MM2<T,U> extends HashMap<T, List<U>>  {
}

Thanks for all your help. I will look into some of the other answers later in the week.

Many thanks
Richard

Back to comp.lang.java.programmer | Previous | NextNext in thread | Find similar | Unroll thread


Thread

Re: Generics for a multiplevalue hashmap Richard <iamrichardjones@gmail.com> - 2011-07-19 13:32 -0700
  Re: Generics for a multiplevalue hashmap Arne Vajhøj <arne@vajhoej.dk> - 2011-07-21 17:15 -0400
    Re: Generics for a multiplevalue hashmap lewbloch <lewbloch@gmail.com> - 2011-07-21 15:30 -0700

csiph-web