org.granite.gravity
Interface Channel

All Known Implementing Classes:
AbstractChannel, AsyncChannel, ContinuationChannel, ContinuationChannel, GAEChannel, GenericChannel, GlassFishWebSocketChannel, JBossWebChannel, JettyWebSocketChannel, JMFAsyncChannel, TomcatChannel, TomcatWebSocketChannel, WebLogicChannel

public interface Channel

Author:
Franck WOLFF

Method Summary
 Subscription addSubscription(String destination, String subTopicId, String subscriptionId, boolean noLocal)
           
 void close()
           
 void destroy(boolean timeout)
           
 String getClientType()
           
 ChannelFactory<?> getFactory()
           
 Gravity getGravity()
           
 String getId()
           
 Collection<Subscription> getSubscriptions()
           
 boolean hasPublishedMessage()
           
 boolean hasReceivedMessage()
           
 void publish(AsyncPublishedMessage message)
           
 void receive(AsyncMessage message)
           
 Subscription removeSubscription(String subscriptionId)
           
 boolean runPublish()
           
 boolean runReceive()
           
 boolean runReceived(AsyncHttpContext asyncHttpContext)
           
 

Method Detail

getId

String getId()

getClientType

String getClientType()

getGravity

Gravity getGravity()

getFactory

ChannelFactory<?> getFactory()

addSubscription

Subscription addSubscription(String destination,
                             String subTopicId,
                             String subscriptionId,
                             boolean noLocal)

getSubscriptions

Collection<Subscription> getSubscriptions()

removeSubscription

Subscription removeSubscription(String subscriptionId)

publish

void publish(AsyncPublishedMessage message)
             throws MessagePublishingException
Throws:
MessagePublishingException

hasPublishedMessage

boolean hasPublishedMessage()

runPublish

boolean runPublish()

receive

void receive(AsyncMessage message)
             throws MessageReceivingException
Throws:
MessageReceivingException

hasReceivedMessage

boolean hasReceivedMessage()

runReceive

boolean runReceive()

runReceived

boolean runReceived(AsyncHttpContext asyncHttpContext)

close

void close()

destroy

void destroy(boolean timeout)