[concurrency-interest] BlockingDeque and revised Deque

Osvaldo Pinali Doederlein osvaldo@visionnaire.com.br
Mon, 29 Nov 2004 08:09:48 -0300


Tim Peierls wrote:
> Joshua Bloch wrote:
> 
>> I wouldn't mind jamming both adapters into
>> java.util.Collections unless asLifoBlockingQueue is the first in a
>> long line.
> 
> I'm sure there will be more. I'd like to have asPutOnlyBlockingQueue
> and asTakeOnlyBlockingQueue, for starters. No, it isn't hard to roll
> your own, but it is tedious. I think it's important to have them for
> passing queues into contexts where it is impossible to guarantee that
> the recipient will observe the required protocol.
> 
> So I'm in favor of j.u.c.ConcurrentCollections, especially if a shorter
> name can be found.

With the availability of static imports, this should'n be an issue.
Just make sure that there are no conflicts (methods with identical
signatures) with java.util.Collections, so I can static-import both
in my collections-heavy sources.

A+
Osvaldo

-- 
-----------------------------------------------------------------------
Osvaldo Pinali Doederlein                   Visionnaire Informática S/A
osvaldo@visionnaire.com.br                http://www.visionnaire.com.br
Arquiteto de Tecnologia                          +55 (41) 337-1000 #223