public class FiberForAllSessions extends java.lang.Object implements NewSessionHandler, ClientPublisher
Constructor and Description |
---|
FiberForAllSessions(NewFiberSessionHandler fact,
org.jetlang.fibers.Fiber fiber,
BufferedSerializer serializer) |
Modifier and Type | Method and Description |
---|---|
java.util.Collection<JetlangFiberSession> |
getAllSessions() |
void |
onNewSession(ClientPublisher unused,
JetlangSession jetlangSession) |
void |
publishToAllSubscribedClients(java.lang.String topic,
java.lang.Object msg)
Should be invoked from the single fiber that maintains the sessions.
|
public FiberForAllSessions(NewFiberSessionHandler fact, org.jetlang.fibers.Fiber fiber, BufferedSerializer serializer)
public void onNewSession(ClientPublisher unused, JetlangSession jetlangSession)
onNewSession
in interface NewSessionHandler
public java.util.Collection<JetlangFiberSession> getAllSessions()
public void publishToAllSubscribedClients(java.lang.String topic, java.lang.Object msg)
publishToAllSubscribedClients
in interface ClientPublisher
Copyright © 2019. All Rights Reserved.