On Fri, 21 Jul 2023 16:48:12 GMT, Stuart Marks <sma...@openjdk.org> wrote:

> ListIterator fuses three different concepts: the ability to traverse forwards 
> and
> backwards, the ability to mutate the underlying List at the current location
> (add/remove/set), and the index of the current location. Which of these is 
> important
> to your use case? What operations would be helpful?

My specific use case requires bidirectional iteration of a LinkedHashMap along 
with ability to remove items. It wouldn't need to be a ListIterator 
specifically, but once one has a collection with both a size and bidirectional 
iterator, it's trivial to turn it into a List via an AbstractSequentialList 
adapter. If this has already been looked into, by all means leave as is. I 
thought maybe it was an unexplored oversight.

-------------

PR Comment: https://git.openjdk.org/jdk/pull/7387#issuecomment-1646013953

Reply via email to