[concurrency-interest] Deque and skip list integration

Luke Blanshard blanshlu@netscape.net
Thu, 30 Dec 2004 07:49:19 -0600


--------------040706060602040502040902
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit

I'd like to be able to look at or poll for the first entry.  I'd like to 
be able to construct views that begin, end, or are bounded by particular 
keys.  Or that yield the same collection in reverse order.  Obviously 
not all the methods currently in the Navigable interfaces apply to 
unsorted-but-ordered collections, but just as obviously a good and 
useful subset of them do.  The ones that require sortedness should be 
split into their own interfaces that also inherit from the Sorted and 
unsorted Navigable interfaces.

Luke

dl@cs.oswego.edu wrote:

>>Here's a complaint AND a suggestion.  You didn't update LinkedHashSet 
>>and LinkedHashMap with any of these useful new methods you've put in to 
>>the Navigable interfaces.  In fact, you've gone and made the Navigable 
>>interfaces require sortedness.  As a frequent user of the LinkedHash 
>>classes, I'd sure like to see the Navigable interfaces depend only on a 
>>defined order, and if need be add NavigableSortedSet and 
>>NavigableSortedMap that unifies the Navigable and Sorted interfaces.
>>    
>>
>
>Sorry, I don't think Navigable can be made to apply when ordering is
>only implicit, not key-based. For example, what should ceilingEntry
>return in a LinkedHashMap, especially for a key that isn't present?
>
>What would you like to do with a LinkedHashMap that you now cannot?
>
>-Doug
>  
>

--------------040706060602040502040902
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
  <title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
I'd like to be able to look at or poll for the first entry.&nbsp; I'd like
to be able to construct views that begin, end, or are bounded by
particular keys.&nbsp; Or that yield the same collection in reverse order.&nbsp;
Obviously not all the methods currently in the Navigable interfaces
apply to unsorted-but-ordered collections, but just as obviously a good
and useful subset of them do.&nbsp; The ones that require sortedness should
be split into their own interfaces that also inherit from the Sorted
and unsorted Navigable interfaces.<br>
<br>
Luke<br>
<br>
<a class="moz-txt-link-abbreviated" href="mailto:dl@cs.oswego.edu">dl@cs.oswego.edu</a> wrote:<br>
<blockquote cite="mid16852.174.52454.818705@altair.cs.oswego.edu"  type="cite">
  <blockquote type="cite">
    <pre wrap="">Here's a complaint AND a suggestion.  You didn't update LinkedHashSet 
and LinkedHashMap with any of these useful new methods you've put in to 
the Navigable interfaces.  In fact, you've gone and made the Navigable 
interfaces require sortedness.  As a frequent user of the LinkedHash 
classes, I'd sure like to see the Navigable interfaces depend only on a 
defined order, and if need be add NavigableSortedSet and 
NavigableSortedMap that unifies the Navigable and Sorted interfaces.
    </pre>
  </blockquote>
  <pre wrap=""><!---->
Sorry, I don't think Navigable can be made to apply when ordering is
only implicit, not key-based. For example, what should ceilingEntry
return in a LinkedHashMap, especially for a key that isn't present?

What would you like to do with a LinkedHashMap that you now cannot?

-Doug
  </pre>
</blockquote>
</body>
</html>

--------------040706060602040502040902--