Class WebSocketUrlHandlerImpl
- java.lang.Object
-
- org.webswing.server.services.websocket.WebSocketUrlHandlerImpl
-
- All Implemented Interfaces:
UrlHandler,WebSocketMessageListener,WebSocketUrlHandler
public class WebSocketUrlHandlerImpl extends Object implements WebSocketUrlHandler
-
-
Constructor Summary
Constructors Constructor Description WebSocketUrlHandlerImpl(PrimaryUrlHandler parent, String path, WebSocketService websocket, SwingInstanceManager instanceManager)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcheckMasterPermission(org.webswing.server.services.security.api.WebswingAction action)voidcheckPermission(org.webswing.server.services.security.api.WebswingAction action)voiddestroy()StringgetFullPathMapping()longgetLastModified(javax.servlet.http.HttpServletRequest req)UrlHandlergetOwner()StringgetPathMapping()UrlHandlergetRootHandler()StringgetSecuredPath()SecuredPathHandlergetSecurityProvider()javax.servlet.ServletContextgetServletContext()org.webswing.server.services.security.api.AbstractWebswingUsergetUser()voidinit()booleanisReady()voidonDisconnect(WebSocketConnection r)voidonMessage(WebSocketConnection r, Object message)voidonReady(WebSocketConnection r)voidonTimeout(WebSocketConnection event)voidregisterChildUrlHandler(UrlHandler handler)voidregisterFirstChildUrlHandler(UrlHandler handler)voidremoveChildUrlHandler(UrlHandler Handler)booleanserve(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse res)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.webswing.server.services.websocket.WebSocketUrlHandler
serveDefault
-
-
-
-
Constructor Detail
-
WebSocketUrlHandlerImpl
public WebSocketUrlHandlerImpl(PrimaryUrlHandler parent, String path, WebSocketService websocket, SwingInstanceManager instanceManager)
-
-
Method Detail
-
init
public void init()
- Specified by:
initin interfaceUrlHandler
-
destroy
public void destroy()
- Specified by:
destroyin interfaceUrlHandler
-
serve
public boolean serve(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse res) throws org.webswing.server.model.exception.WsException- Specified by:
servein interfaceUrlHandler- Throws:
org.webswing.server.model.exception.WsException
-
onReady
public void onReady(WebSocketConnection r)
- Specified by:
onReadyin interfaceWebSocketMessageListener
-
onDisconnect
public void onDisconnect(WebSocketConnection r)
- Specified by:
onDisconnectin interfaceWebSocketMessageListener
-
onMessage
public void onMessage(WebSocketConnection r, Object message)
- Specified by:
onMessagein interfaceWebSocketMessageListener
-
onTimeout
public void onTimeout(WebSocketConnection event)
- Specified by:
onTimeoutin interfaceWebSocketMessageListener
-
getOwner
public UrlHandler getOwner()
- Specified by:
getOwnerin interfaceWebSocketMessageListener
-
registerFirstChildUrlHandler
public void registerFirstChildUrlHandler(UrlHandler handler)
- Specified by:
registerFirstChildUrlHandlerin interfaceUrlHandler
-
registerChildUrlHandler
public void registerChildUrlHandler(UrlHandler handler)
- Specified by:
registerChildUrlHandlerin interfaceUrlHandler
-
removeChildUrlHandler
public void removeChildUrlHandler(UrlHandler Handler)
- Specified by:
removeChildUrlHandlerin interfaceUrlHandler
-
getLastModified
public long getLastModified(javax.servlet.http.HttpServletRequest req)
- Specified by:
getLastModifiedin interfaceUrlHandler
-
getPathMapping
public String getPathMapping()
- Specified by:
getPathMappingin interfaceUrlHandler
-
getFullPathMapping
public String getFullPathMapping()
- Specified by:
getFullPathMappingin interfaceUrlHandler
-
getSecuredPath
public String getSecuredPath()
- Specified by:
getSecuredPathin interfaceUrlHandler
-
getRootHandler
public UrlHandler getRootHandler()
- Specified by:
getRootHandlerin interfaceUrlHandler
-
getUser
public org.webswing.server.services.security.api.AbstractWebswingUser getUser()
- Specified by:
getUserin interfaceUrlHandler
-
checkPermission
public void checkPermission(org.webswing.server.services.security.api.WebswingAction action) throws org.webswing.server.model.exception.WsException- Specified by:
checkPermissionin interfaceUrlHandler- Throws:
org.webswing.server.model.exception.WsException
-
getSecurityProvider
public SecuredPathHandler getSecurityProvider()
- Specified by:
getSecurityProviderin interfaceUrlHandler
-
getServletContext
public javax.servlet.ServletContext getServletContext()
- Specified by:
getServletContextin interfaceUrlHandler
-
checkMasterPermission
public void checkMasterPermission(org.webswing.server.services.security.api.WebswingAction action) throws org.webswing.server.model.exception.WsException- Specified by:
checkMasterPermissionin interfaceUrlHandler- Throws:
org.webswing.server.model.exception.WsException
-
isReady
public boolean isReady()
- Specified by:
isReadyin interfaceWebSocketMessageListener
-
-