org.granite.gravity.generic
Class GenericChannel

java.lang.Object
  extended by org.granite.gravity.AbstractChannel
      extended by org.granite.gravity.generic.GenericChannel
All Implemented Interfaces:
Channel

public class GenericChannel
extends AbstractChannel

Author:
William DRAI

Field Summary
 
Fields inherited from class org.granite.gravity.AbstractChannel
id, publishedQueue, publishedQueueLock, publisher, receivedQueue, receivedQueueLock, receiver, servletConfig, subscriptions
 
Constructor Summary
GenericChannel(ServletConfig servletConfig, GravityConfig gravityConfig, String id)
           
 
Method Summary
protected  AsyncHttpContext acquireAsyncHttpContext()
           
 void destroy()
           
protected  boolean hasAsyncHttpContext()
           
 boolean isLocal()
           
 void receive(AsyncMessage message)
           
protected  void releaseAsyncHttpContext(AsyncHttpContext context)
           
 void reset()
           
 void resume()
           
 void setContinuation(WaitingContinuation continuation)
           
 
Methods inherited from class org.granite.gravity.AbstractChannel
addSubscription, equals, getGravity, getId, getServletConfig, getServletContext, getSubscriptions, hashCode, hasPublishedMessage, hasReceivedMessage, publish, queueReceiver, removeSubscription, runPublish, runReceive, runReceived, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

GenericChannel

public GenericChannel(ServletConfig servletConfig,
                      GravityConfig gravityConfig,
                      String id)
Method Detail

setContinuation

public void setContinuation(WaitingContinuation continuation)

reset

public void reset()

resume

public void resume()

receive

public void receive(AsyncMessage message)
             throws MessageReceivingException
Specified by:
receive in interface Channel
Overrides:
receive in class AbstractChannel
Throws:
MessageReceivingException

hasAsyncHttpContext

protected boolean hasAsyncHttpContext()
Specified by:
hasAsyncHttpContext in class AbstractChannel

releaseAsyncHttpContext

protected void releaseAsyncHttpContext(AsyncHttpContext context)
Specified by:
releaseAsyncHttpContext in class AbstractChannel

acquireAsyncHttpContext

protected AsyncHttpContext acquireAsyncHttpContext()
Specified by:
acquireAsyncHttpContext in class AbstractChannel

isLocal

public boolean isLocal()

destroy

public void destroy()
Specified by:
destroy in interface Channel
Overrides:
destroy in class AbstractChannel