|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface ServerChannel
Server side representation of a Bayeux Channel.
The ServerChannel is the entity that holds the set of
ServerSessions that are subscribed to a channel.
A message published to a ServerChannel will be delivered to
all the ServerSession's subscribed to the channel.
A ServerChannel is distinct from a SessionChannel,
which is the client side representation of a channel (note there
can be clients within the server JVM).
| Nested Class Summary | |
|---|---|
static interface |
ServerChannel.MessageListener
|
static interface |
ServerChannel.ServerChannelListener
|
static interface |
ServerChannel.SubscriptionListener
|
| Field Summary |
|---|
| Fields inherited from interface org.cometd.bayeux.Channel |
|---|
META_CONNECT, META_DISCONNECT, META_HANDSHAKE, META_SUBSCRIBE, META_UNSUBSCRIBE |
| Method Summary | |
|---|---|
void |
addListener(ServerChannel.ServerChannelListener listener)
|
java.util.Set<? extends ServerSession> |
getSubscribers()
|
boolean |
isBroadcast()
|
boolean |
isLazy()
|
boolean |
isPersistent()
|
void |
publish(Session from,
java.lang.Object data,
java.lang.Object id)
Publish a message to the channel. |
void |
publish(Session from,
ServerMessage message)
Publish a message to the channel. |
void |
remove()
Remove a channel |
void |
removeListener(ServerChannel.ServerChannelListener listener)
|
void |
setLazy(boolean lazy)
Set lazy channel |
void |
setPersistent(boolean persistent)
Set persistent channel |
| Methods inherited from interface org.cometd.bayeux.Channel |
|---|
getId, isDeepWild, isMeta, isService, isWild |
| Method Detail |
|---|
void addListener(ServerChannel.ServerChannelListener listener)
listener - void removeListener(ServerChannel.ServerChannelListener listener)
listener - java.util.Set<? extends ServerSession> getSubscribers()
boolean isBroadcast()
boolean isLazy()
boolean isPersistent()
void setLazy(boolean lazy)
lazy - If true, all messages published to this channel will
be marked as lazy.void setPersistent(boolean persistent)
persistent - If true, the channel will not be removed when
the last subscription is removed.
void publish(Session from,
ServerMessage message)
Delivered a message to all the ServerSession's
subscribed to the channel.
message -
void publish(Session from,
java.lang.Object data,
java.lang.Object id)
Delivered a message to all the ServerSession's
subscribed to the channel.
data - void remove()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||