Class CommonServerEventWebSocket
- java.lang.Object
-
- org.silverpeas.core.webapi.notification.sse.SilverpeasServerEventWebSocket
-
- org.silverpeas.core.webapi.notification.sse.CommonServerEventWebSocket
-
public class CommonServerEventWebSocket extends SilverpeasServerEventWebSocket
- Author:
- silveryocha
-
-
Constructor Summary
Constructors Constructor Description CommonServerEventWebSocket()
-
Method Summary
All Methods Instance Methods Concrete Methods Default Methods Modifier and Type Method Description protected String
getTokenParameterName()
Gets the name of the parameter representing the token generated for current authenticated user and passed in the URI of the WebSocket endpoint.default void
prepareEventsOnOpening(org.silverpeas.core.webapi.notification.sse.SilverpeasServerEventWebAccess.WebAccessContext wac, Long initialLastServerEventId)
default void
send(org.silverpeas.core.webapi.notification.sse.SilverpeasServerEventWebAccess.WebAccessContext wac, SilverpeasServerEventContext context)
-
Methods inherited from class org.silverpeas.core.webapi.notification.sse.SilverpeasServerEventWebSocket
getSessionInfo, onClose, onError, onMessage, onOpen
-
-
-
-
Method Detail
-
getTokenParameterName
protected String getTokenParameterName()
Description copied from class:SilverpeasServerEventWebSocket
Gets the name of the parameter representing the token generated for current authenticated user and passed in the URI of the WebSocket endpoint.For example: With the
@ServerEndpoint("/ws/{token}/sse/common")
declaration, "token" MUST be returned by this method.- Specified by:
getTokenParameterName
in classSilverpeasServerEventWebSocket
- Returns:
- a string representing the parameter name for the token.
-
prepareEventsOnOpening
public default void prepareEventsOnOpening(org.silverpeas.core.webapi.notification.sse.SilverpeasServerEventWebAccess.WebAccessContext wac, Long initialLastServerEventId)
-
send
public default void send(org.silverpeas.core.webapi.notification.sse.SilverpeasServerEventWebAccess.WebAccessContext wac, SilverpeasServerEventContext context) throws IOException
- Throws:
IOException
-
-