com.sun.grizzly.cometd
Class BayeuxCometHandler

java.lang.Object
  extended by com.sun.grizzly.cometd.BayeuxCometHandlerBase
      extended by com.sun.grizzly.cometd.BayeuxCometHandler
All Implemented Interfaces:
CometHandler, CometdHandler

public class BayeuxCometHandler
extends BayeuxCometHandlerBase

This class implement the Bauyeux Server side protocol.

Author:
Jeanfrancois Arcand, TAKAI, Naoto

Field Summary
static String BAYEUX_COMET_HANDLER
           
static String DEFAULT_CONTENT_TYPE
           
 
Constructor Summary
BayeuxCometHandler()
           
 
Method Summary
 String getChannel()
           
static CometdContext newCometdContext(CometdRequest req, CometdResponse res, Verb verb)
           
 void onConnect(CometEvent event)
           
 void onDisconnect(CometEvent event)
           
 void onHandshake(CometEvent event)
           
 void onInterrupt(CometEvent event)
          Receive CometEvent notification when the underlying tcp communication is resumed by the Grizzly ARP.
 void onPing(CometEvent event)
           
 void onPublish(CometEvent event)
           
 void onReconnect(CometEvent event)
           
 void onStatus(CometEvent event)
           
 void onSubscribe(CometEvent event)
           
 void onTerminate(CometEvent event)
          Receive CometEvent notification when the underlying tcp communication is closed by the CometHandler
 void onUnsubscribe(CometEvent event)
           
 void setChannel(String channel)
           
 
Methods inherited from class com.sun.grizzly.cometd.BayeuxCometHandlerBase
attach, onEvent, onInitialize
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_CONTENT_TYPE

public static final String DEFAULT_CONTENT_TYPE
See Also:
Constant Field Values

BAYEUX_COMET_HANDLER

public static final String BAYEUX_COMET_HANDLER
See Also:
Constant Field Values
Constructor Detail

BayeuxCometHandler

public BayeuxCometHandler()
Method Detail

onHandshake

public void onHandshake(CometEvent event)
                 throws IOException
Throws:
IOException

onConnect

public void onConnect(CometEvent event)
               throws IOException
Throws:
IOException

onDisconnect

public void onDisconnect(CometEvent event)
                  throws IOException
Throws:
IOException

onReconnect

public void onReconnect(CometEvent event)
                 throws IOException
Throws:
IOException

onSubscribe

public void onSubscribe(CometEvent event)
                 throws IOException
Throws:
IOException

onUnsubscribe

public void onUnsubscribe(CometEvent event)
                   throws IOException
Throws:
IOException

onPublish

public void onPublish(CometEvent event)
               throws IOException
Throws:
IOException

newCometdContext

public static final CometdContext newCometdContext(CometdRequest req,
                                                   CometdResponse res,
                                                   Verb verb)

onTerminate

public void onTerminate(CometEvent event)
                 throws IOException
Description copied from interface: CometHandler
Receive CometEvent notification when the underlying tcp communication is closed by the CometHandler

Specified by:
onTerminate in interface CometHandler
Overrides:
onTerminate in class BayeuxCometHandlerBase
Throws:
IOException

onInterrupt

public void onInterrupt(CometEvent event)
                 throws IOException
Description copied from interface: CometHandler
Receive CometEvent notification when the underlying tcp communication is resumed by the Grizzly ARP.

Specified by:
onInterrupt in interface CometHandler
Overrides:
onInterrupt in class BayeuxCometHandlerBase
Throws:
IOException

onPing

public void onPing(CometEvent event)
            throws IOException
Throws:
IOException

onStatus

public void onStatus(CometEvent event)
              throws IOException
Throws:
IOException

getChannel

public String getChannel()

setChannel

public void setChannel(String channel)


Copyright © 2008 SUN Microsystems. All Rights Reserved.