Logo Search packages:      
Sourcecode: scala version File versions  Download package

scala::actors::LinkedQueue Class Reference

List of all members.


Detailed Description

A linked list based channel implementation. The algorithm avoids contention between puts and takes when the queue is not empty. Normally a put and a take can proceed simultaneously. (Although it does not allow multiple concurrent puts or takes.) This class tends to perform more efficently than other Channel implementations in producer/consumer applications.

[Introduction to this package. ]

Definition at line 31 of file LinkedQueue.java.


Public Member Functions

boolean isEmpty ()
boolean offer (Object x, long msecs) throws InterruptedException
Object peek ()
Object poll (long msecs) throws InterruptedException
void put (Object x) throws InterruptedException
Object take () throws InterruptedException

Protected Member Functions

synchronized Object extract ()
void insert (Object x)

Protected Attributes

LinkedNode head_
LinkedNode last_
final Object putLock_ = new Object()
int waitingForTake_ = 0

The documentation for this class was generated from the following file:

Generated by  Doxygen 1.6.0   Back to index