use of org.jaggeryjs.hostobjects.web.WebSocketHostObject in project jaggery by wso2.
the class JaggeryWebSocketServlet method doGet.
protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
try {
CommonManager.getInstance().getEngine().enterContext();
} catch (ScriptException e) {
log.error(e.getMessage(), e);
throw new ServletException(e);
}
WebAppManager.execute(request, response);
JaggeryContext context = CommonManager.getJaggeryContext();
Scriptable scope = context.getScope();
wsMessageInBound = new WSMessageInBound((WebSocketHostObject) scope.get("webSocket", scope));
RhinoEngine.exitContext();
super.doGet(request, response);
}
Aggregations