org.apache.cocoon.components.thread
Class ChannelWrapper

java.lang.Object
  extended by org.apache.cocoon.components.thread.ChannelWrapper
All Implemented Interfaces:
EDU.oswego.cs.dl.util.concurrent.Channel, EDU.oswego.cs.dl.util.concurrent.Puttable, EDU.oswego.cs.dl.util.concurrent.Takable

public class ChannelWrapper
extends Object
implements EDU.oswego.cs.dl.util.concurrent.Channel

Wrapper around a Channel implementation for constructor convenience

Version:
$Id: ChannelWrapper.html 1304258 2012-03-23 10:09:27Z ilgrosso $
Author:
Giacomo Pati

Constructor Summary
ChannelWrapper()
           
 
Method Summary
 boolean offer(Object obj, long timeout)
           
 Object peek()
           
 Object poll(long timeout)
           
 void put(Object obj)
           
 void setChannel(EDU.oswego.cs.dl.util.concurrent.Channel channel)
          DOCUMENT ME!
 Object take()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ChannelWrapper

public ChannelWrapper()
Method Detail

setChannel

public void setChannel(EDU.oswego.cs.dl.util.concurrent.Channel channel)
DOCUMENT ME!

Parameters:
channel - DOCUMENT ME!

offer

public boolean offer(Object obj,
                     long timeout)
              throws InterruptedException
Specified by:
offer in interface EDU.oswego.cs.dl.util.concurrent.Channel
Specified by:
offer in interface EDU.oswego.cs.dl.util.concurrent.Puttable
Throws:
InterruptedException
See Also:
Puttable.offer(java.lang.Object, long)

peek

public Object peek()
Specified by:
peek in interface EDU.oswego.cs.dl.util.concurrent.Channel
See Also:
Channel.peek()

poll

public Object poll(long timeout)
            throws InterruptedException
Specified by:
poll in interface EDU.oswego.cs.dl.util.concurrent.Channel
Specified by:
poll in interface EDU.oswego.cs.dl.util.concurrent.Takable
Throws:
InterruptedException
See Also:
Takable.poll(long)

put

public void put(Object obj)
         throws InterruptedException
Specified by:
put in interface EDU.oswego.cs.dl.util.concurrent.Channel
Specified by:
put in interface EDU.oswego.cs.dl.util.concurrent.Puttable
Throws:
InterruptedException
See Also:
Puttable.put(java.lang.Object)

take

public Object take()
            throws InterruptedException
Specified by:
take in interface EDU.oswego.cs.dl.util.concurrent.Channel
Specified by:
take in interface EDU.oswego.cs.dl.util.concurrent.Takable
Throws:
InterruptedException
See Also:
Takable.take()


Copyright © 1999-2010 The Apache Software Foundation. All Rights Reserved.