Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.programmer > #28725
| From | markspace <markspace@nospam.nospam> |
|---|---|
| Newsgroups | comp.lang.java.programmer |
| Subject | Re: Queue and Map interface |
| Date | 2014-06-13 16:52 -0700 |
| Organization | A noiseless patient Spider |
| Message-ID | <lng2sk$8k4$1@dont-email.me> (permalink) |
| References | <lnfoa3$8sn$1@online.de> <lnfql9$hnq$1@dont-email.me> |
On 6/13/2014 2:32 PM, Eric Sosman wrote:
> For even more "favoritism," you could have the outer class
> implement neither Map nor Queue, and delegate both those interfaces
> to inner classes.
>
Or just have two methods to call on some generic object which return a
"view" of that object as either a Map or a Queue.
interface MyCollection {
Map asMap();
Queue asQueue();
}
Back to comp.lang.java.programmer | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Queue and Map interface Philipp Kraus <philipp.kraus@flashpixx.de> - 2014-06-13 22:52 +0200
Re: Queue and Map interface Eric Sosman <esosman@comcast-dot-net.invalid> - 2014-06-13 17:32 -0400
Re: Queue and Map interface markspace <markspace@nospam.nospam> - 2014-06-13 16:52 -0700
Re: Queue and Map interface Philipp Kraus <philipp.kraus@flashpixx.de> - 2014-06-14 07:52 +0200
Re: Queue and Map interface Eric Sosman <esosman@comcast-dot-net.invalid> - 2014-06-14 08:41 -0400
csiph-web