public class LocalSessionImpl extends AbstractClientSession implements LocalSession
This session is local to the BayeuxServer instance and
communicates with the server without any serialization.
The normal Bayeux meta messages are exchanged between the LocalSession
and the ServerSession.
| Modifier and Type | Class and Description |
|---|---|
protected class |
LocalSessionImpl.LocalChannel
A channel scoped to this local session
|
AbstractClientSession.AbstractSessionChannelClientSession.Extensionlogger| Modifier | Constructor and Description |
|---|---|
protected |
LocalSessionImpl(BayeuxServerImpl bayeux,
String idHint) |
| Modifier and Type | Method and Description |
|---|---|
void |
disconnect() |
protected void |
doSend(ServerSessionImpl from,
ServerMessage.Mutable message)
Send a message (to the server).
|
String |
getId() |
ServerSession |
getServerSession() |
void |
handshake() |
void |
handshake(Map<String,Object> template) |
boolean |
isConnected() |
boolean |
isHandshook() |
protected AbstractClientSession.AbstractSessionChannel |
newChannel(ChannelId channelId) |
protected ChannelId |
newChannelId(String channelId) |
void |
receive(Message.Mutable message) |
protected void |
send(ServerSessionImpl session,
ServerMessage.Mutable message)
Send a message (to the server).
|
protected void |
sendBatch() |
String |
toString() |
addExtension, batch, dump, endBatch, extendRcv, extendSend, getAttribute, getAttributeNames, getChannel, getChannels, getExtensions, isBatching, newMessageId, removeAttribute, removeExtension, resetSubscriptions, setAttribute, startBatchclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitaddExtension, getChannel, getExtensions, removeExtensionbatch, endBatch, getAttribute, getAttributeNames, removeAttribute, setAttribute, startBatchprotected LocalSessionImpl(BayeuxServerImpl bayeux, String idHint)
public void receive(Message.Mutable message)
receive in class AbstractClientSessionprotected AbstractClientSession.AbstractSessionChannel newChannel(ChannelId channelId)
newChannel in class AbstractClientSessionAbstractClientSession.newChannel(org.cometd.bayeux.ChannelId)protected ChannelId newChannelId(String channelId)
newChannelId in class AbstractClientSessionAbstractClientSession.newChannelId(java.lang.String)protected void sendBatch()
sendBatch in class AbstractClientSessionAbstractClientSession.sendBatch()public ServerSession getServerSession()
getServerSession in interface LocalSessionpublic void handshake()
handshake in interface ClientSessionpublic void handshake(Map<String,Object> template)
handshake in interface ClientSessionpublic void disconnect()
disconnect in interface Sessionpublic boolean isConnected()
isConnected in interface Sessionpublic boolean isHandshook()
isHandshook in interface Sessionprotected void send(ServerSessionImpl session, ServerMessage.Mutable message)
This method will either batch the message or call doSend(ServerSessionImpl, org.cometd.bayeux.server.ServerMessage.Mutable)
session - The ServerSession to send as. This normally the current server session, but during handshake it is a proposed server session.message - The message to send.protected void doSend(ServerSessionImpl from, ServerMessage.Mutable message)
Extends and sends the message without batching.
from - The ServerSession to send as. This normally the current server session, but during handshake it is a proposed server session.message - The message to send.Copyright © 2008-2012 Dojo Foundation. All Rights Reserved.