himanshudixit / google-collections

Automatically exported from code.google.com/p/google-collections
Apache License 2.0
0 stars 0 forks source link

LinkedListMultimap values should be of type Deque<V> #302

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
This would be useful for head and tail access.

Original issue reported on code.google.com by joern.ba...@gmail.com on 25 Nov 2009 at 7:47

GoogleCodeExporter commented 9 years ago
Our library supports Java 1.5, so we can't use Deque. :(

Original comment by kevin...@gmail.com on 25 Nov 2009 at 7:53

GoogleCodeExporter commented 9 years ago
Issue 288 asks for LinkedListMultimap.values() to return a List.
http://code.google.com/p/google-collections/issues/detail?id=288

That would provide the relevant Deque functionality, since you could then 
retrieve a 
ListIterator pointing to the end of the list:
  multimap.values().listIterator(multimap.size());

A ListIterator is less convenient than a Deque, but at least it's feasible with 
Java 
5.

Original comment by jared.l....@gmail.com on 25 Nov 2009 at 8:10

GoogleCodeExporter commented 9 years ago
@Deque, right my mistake. Will use ListIterator as workaround. Thanks!

Original comment by joern.ba...@gmail.com on 25 Nov 2009 at 8:18