Package com.logicaldoc.web.websockets
Class EventEndpoint
- java.lang.Object
-
- com.logicaldoc.web.websockets.EventEndpoint
-
- All Implemented Interfaces:
EventListener
public class EventEndpoint extends Object implements EventListener
Websockets end-point to distribute events.- Since:
- 8.1.1
- Author:
- Marco Meschieri - LogicalDOC
-
-
Constructor Summary
Constructors Constructor Description EventEndpoint()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static void
distributeMessage(WebsocketMessage message)
Distributes a message to all the connected clientsvoid
error(javax.websocket.Session session, Throwable t)
void
newEvent(History event)
void
onBinaryMessage(byte[] data, javax.websocket.Session session)
void
onClose(javax.websocket.Session session)
void
onMessage(String message, javax.websocket.Session session)
void
onOpen(javax.websocket.Session session)
-
-
-
Method Detail
-
onOpen
public void onOpen(javax.websocket.Session session)
-
onClose
public void onClose(javax.websocket.Session session)
-
onMessage
public void onMessage(String message, javax.websocket.Session session)
-
onBinaryMessage
public void onBinaryMessage(byte[] data, javax.websocket.Session session)
-
newEvent
public void newEvent(History event)
- Specified by:
newEvent
in interfaceEventListener
-
error
public void error(javax.websocket.Session session, Throwable t)
-
distributeMessage
public static void distributeMessage(WebsocketMessage message)
Distributes a message to all the connected clients- Parameters:
message
- The message to be sent
-
-