Package org.directwebremoting

Examples of org.directwebremoting.WebContext


    private static Decipherer decipherer;
    private static Cipherer cipherer;
    private static Log log = LogFactory.getLog(EncryptedUUIDConverter.class);

    protected void initEncryption() {
        WebContext webCtx = WebContextFactory.get();
        WebApplicationContext springContext = RequestContextUtils.getWebApplicationContext(webCtx.getHttpServletRequest(), webCtx.getServletContext());
        decipherer = (Decipherer) springContext.getBean("cryptographyManager");
        cipherer = (Cipherer) decipherer;
        if (log.isInfoEnabled()) log.info("UUID converter found cipherer/decipherer: " + decipherer.getClass().getName());
    }
View Full Code Here


    private static Decipherer decipherer;
    private static Cipherer cipherer;
    private static Log log = LogFactory.getLog(EncryptedClassConverter.class);

    protected void initEncryption() {
        WebContext webCtx = WebContextFactory.get();
        WebApplicationContext springContext = RequestContextUtils.getWebApplicationContext(webCtx.getHttpServletRequest(), webCtx.getServletContext());
        decipherer = (Decipherer) springContext.getBean("cryptographyManager");
        cipherer = (Cipherer) decipherer;
        if (log.isInfoEnabled()) log.info("Class converter found cipherer/decipherer: " + decipherer.getClass().getName());
    }
View Full Code Here

        return getViewPointData(user, view, edit);
    }

    private List<ViewComponentState> getViewPointData(User user, GraphicalView view, boolean edit) {
        WebContext webContext = WebContextFactory.get();
        HttpServletRequest request = webContext.getHttpServletRequest();
        List<ViewComponentState> states = new ArrayList<ViewComponentState>();
        Map<String, Object> model = new HashMap<String, Object>();

        for (ViewComponent viewComponent : view.getViewComponents()) {
            if (viewComponent.isCompoundComponent() && (edit || viewComponent.isVisible())) {
View Full Code Here

      return dane;

    } catch (Exception e) {
      e.printStackTrace();
      //pobranie req przy Ajaxie DWR
      WebContext ctx = WebContextFactory.get();
      HttpServletRequest req = ctx.getHttpServletRequest();
      throw new Exception(MessageUtil.getMessage("stanowiska.table.exception", req.getLocale()));
    }
  }
View Full Code Here

      return dane;

    } catch (Exception e) {
      e.printStackTrace();
      //pobranie req przy Ajaxie DWR
      WebContext ctx = WebContextFactory.get();
      HttpServletRequest req = ctx.getHttpServletRequest();
      throw new Exception(MessageUtil.getMessage("stanowiska.table.exception", req.getLocale()));
    }
   
  }
View Full Code Here

    return response;
   
  }
 
  public String cos(){
    WebContext webContext = WebContextFactory.get();
    ServletContext servletContext = webContext.getServletContext();

    ServerContext serverContext = ServerContextFactory.get(servletContext);
    Iterator iterator = serverContext.getAllScriptSessions().iterator();
    String currentPage = webContext.getCurrentPage();
    serverContext.getScriptSessionsByPage(currentPage);
    while(iterator.hasNext()){
      ScriptProxy proxy = new ScriptProxy((ScriptSession) iterator.next());
      proxy.addFunctionCall("redirect");
    }
View Full Code Here

     * @deprecated Use WebContextFactory.get() for better results
     */
    @Deprecated
    public static ExecutionContext get()
    {
        WebContext context = WebContextFactory.get();
        if (context == null)
        {
            return null;
        }

View Full Code Here

    }

    public void invoke(Object[] args) {

        // TODO: this only works if its the same thread as request
        WebContext wctx = WebContextFactory.get();
        String currentPage = wctx.getCurrentPage();

        // Get a DWR Util proxy for all the browsers on the current page:
        Collection sessions = wctx.getScriptSessionsByPage(currentPage);
        Util utilAll = new Util(sessions);

        ScriptBuffer referenceInvoke = getInvokeFragment(args, wctx);

        // add the reference call to the Util proxy which will cause DWR to
View Full Code Here

    }

    public void invoke(Object[] args) {

        // TODO: this only works if its the same thread as request
        WebContext wctx = WebContextFactory.get();
        String currentPage = wctx.getCurrentPage();

        // Get a DWR Util proxy for all the browsers on the current page:
        Collection sessions = wctx.getScriptSessionsByPage(currentPage);
        Util utilAll = new Util(sessions);

        ScriptBuffer referenceInvoke = getInvokeFragment(args, wctx);

        // add the reference call to the Util proxy which will cause DWR to
View Full Code Here

    }

    public void invoke(Object[] args) {

        // TODO: this only works if its the same thread as request
        WebContext wctx = WebContextFactory.get();
        String currentPage = wctx.getCurrentPage();

        // Get a DWR Util proxy for all the browsers on the current page:
        Collection sessions = wctx.getScriptSessionsByPage(currentPage);
        Util utilAll = new Util(sessions);

        ScriptBuffer referenceInvoke = getInvokeFragment(args, wctx);

        // add the reference call to the Util proxy which will cause DWR to
View Full Code Here

TOP

Related Classes of org.directwebremoting.WebContext

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.