Examples of RedirectPolicy


Examples of org.apache.wicket.request.handler.RenderPageRequestHandler.RedirectPolicy

      {
        // schedule page render after current request handler is done. this can be
        // overridden
        // during invocation of listener
        // method (i.e. by calling RequestCycle#setResponsePage)
        RedirectPolicy policy = page.isPageStateless() ? RedirectPolicy.NEVER_REDIRECT
          : RedirectPolicy.AUTO_REDIRECT;
        requestCycle.scheduleRequestHandlerAfterCurrent(new RenderPageRequestHandler(
          new PageProvider(page), policy));
      }
View Full Code Here

Examples of org.apache.wicket.request.handler.RenderPageRequestHandler.RedirectPolicy

      {
        // schedule page render after current request handler is done. this can be
        // overridden
        // during invocation of listener
        // method (i.e. by calling RequestCycle#setResponsePage)
        RedirectPolicy policy = getPage().isPageStateless() ? RedirectPolicy.NEVER_REDIRECT
          : RedirectPolicy.AUTO_REDIRECT;
        requestCycle.scheduleRequestHandlerAfterCurrent(new RenderPageRequestHandler(
          new PageProvider(getPage()), policy));
      }
View Full Code Here

Examples of org.apache.wicket.request.handler.RenderPageRequestHandler.RedirectPolicy

      {
        // schedule page render after current request handler is done. this can be
        // overridden
        // during invocation of listener
        // method (i.e. by calling RequestCycle#setResponsePage)
        RedirectPolicy policy = getPage().isPageStateless() ? RedirectPolicy.NEVER_REDIRECT
          : RedirectPolicy.AUTO_REDIRECT;
        requestCycle.scheduleRequestHandlerAfterCurrent(new RenderPageRequestHandler(
          new PageProvider(getPage()), policy));
      }
View Full Code Here

Examples of org.apache.wicket.request.handler.RenderPageRequestHandler.RedirectPolicy

        // initialize the page to be able to check whether it is stateless
        ((Page)page).internalInitialize();
      }
      final boolean isStateless = page.isPageStateless();

      RedirectPolicy policy = isStateless ? RedirectPolicy.NEVER_REDIRECT
        : RedirectPolicy.AUTO_REDIRECT;
      final IPageProvider pageProvider = new PageProvider(page);

      if (freshPage && isStateless == false)
      {
View Full Code Here

Examples of org.apache.wicket.request.handler.RenderPageRequestHandler.RedirectPolicy

        // initialize the page to be able to check whether it is stateless
        ((Page)page).internalInitialize();
      }
      final boolean isStateless = page.isPageStateless();

      RedirectPolicy policy = isStateless ? RedirectPolicy.NEVER_REDIRECT
        : RedirectPolicy.AUTO_REDIRECT;
      final IPageProvider pageProvider = new PageProvider(page);

      if (freshPage && (isStateless == false || component == null))
      {
View Full Code Here

Examples of org.apache.wicket.request.handler.RenderPageRequestHandler.RedirectPolicy

        // initialize the page to be able to check whether it is stateless
        ((Page)page).internalInitialize();
      }
      final boolean isStateless = page.isPageStateless();

      RedirectPolicy policy = isStateless ? RedirectPolicy.NEVER_REDIRECT
        : RedirectPolicy.AUTO_REDIRECT;
      final IPageProvider pageProvider = new PageProvider(page);

      if (freshPage && isStateless == false)
      {
View Full Code Here

Examples of org.apache.wicket.request.handler.RenderPageRequestHandler.RedirectPolicy

      {
        // schedule page render after current request handler is done. this can be
        // overridden during invocation of listener
        // method (i.e. by calling RequestCycle#setResponsePage)
        final IPageProvider pageProvider = new PageProvider(page);
        final RedirectPolicy policy = page.isPageStateless()
          ? RedirectPolicy.NEVER_REDIRECT : RedirectPolicy.AUTO_REDIRECT;

        requestCycle.scheduleRequestHandlerAfterCurrent(new RenderPageRequestHandler(
          pageProvider, policy));
      }
View Full Code Here

Examples of org.apache.wicket.request.handler.RenderPageRequestHandler.RedirectPolicy

      {
        // schedule page render after current request handler is done. this can be
        // overridden
        // during invocation of listener
        // method (i.e. by calling RequestCycle#setResponsePage)
        RedirectPolicy policy = getPage().isPageStateless() ? RedirectPolicy.NEVER_REDIRECT
          : RedirectPolicy.AUTO_REDIRECT;
        requestCycle.scheduleRequestHandlerAfterCurrent(new RenderPageRequestHandler(
          new PageProvider(getPage()), policy));
      }
View Full Code Here

Examples of org.apache.wicket.request.handler.RenderPageRequestHandler.RedirectPolicy

     */
    @Override
    public IRequestHandler onException(RequestCycle cycle, Exception error)
    {
        Class<? extends Page> respondWithPage = null;
        RedirectPolicy redirectPolicy = RedirectPolicy.NEVER_REDIRECT;
       
        if(error instanceof AuthorizationException)
        {
            AuthorizationException ae = (AuthorizationException) error;
            if(authenticationNeeded(ae))
View Full Code Here

Examples of org.apache.wicket.request.handler.RenderPageRequestHandler.RedirectPolicy

     * a redirect. However, if the request is an ajax one, force a redirect, as that is the
     * only way to make the browser show the error page.
     */
    private IRequestHandler createErrorPageHandler(RequestCycle cycle, Class<? extends Page> page)
    {
        RedirectPolicy redirectPolicy = RedirectPolicy.NEVER_REDIRECT;
       
        if(cycle.getRequest() instanceof WebRequest && ((WebRequest) cycle.getRequest()).isAjax())
        {
            redirectPolicy = RedirectPolicy.ALWAYS_REDIRECT;
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.