Package org.apache.wicket.request.http

Examples of org.apache.wicket.request.http.WebRequest


    super.renderHead(component, response);

    response.render(JavaScriptHeaderItem.forScript("if (typeof(Wicket.TimerHandles) === 'undefined') {Wicket.TimerHandles = {}}",
        WICKET_TIMERS_ID));

    WebRequest request = (WebRequest) component.getRequest();

    if (!isStopped() && (!headRendered || !request.isAjax()))
    {
      headRendered = true;
      response.render(OnLoadHeaderItem.forScript(getJsTimeoutCall(updateInterval)));
    }
  }
View Full Code Here


    boolean isAjax = false;

    Request request = requestCycle.getRequest();
    if (request instanceof WebRequest)
    {
      WebRequest webRequest = (WebRequest)request;
      isAjax = webRequest.isAjax();
    }

    return isAjax;
  }
View Full Code Here

   * @return the markup id of the focused element in the browser
   */
  @Override
  public String getLastFocusedElementId()
  {
    WebRequest request = (WebRequest)page.getRequest();
    String id = request.getHeader("Wicket-FocusedElementId");
    return Strings.isEmpty(id) ? null : id;
  }
View Full Code Here

  @Override
  public void renderHead(Component component, IHeaderResponse response)
  {
    super.renderHead(component, response);

    WebRequest request = (WebRequest) component.getRequest();

    if (!isStopped() && (!headRendered || !request.isAjax()))
    {
      headRendered = true;
      response.render(OnLoadHeaderItem.forScript(getJsTimeoutCall(updateInterval)));
    }
  }
View Full Code Here

     * @return <code>true</code> if the resource data does need to be written,
     *         <code>false</code> otherwise.
     */
    public boolean dataNeedsToBeWritten(Attributes attributes)
    {
      WebRequest request = (WebRequest)attributes.getRequest();
      Time ifModifiedSince = request.getIfModifiedSinceHeader();

      if (cacheDuration != Duration.NONE && ifModifiedSince != null && lastModified != null)
      {
        // [Last-Modified] headers have a maximum precision of one second
        // so we have to truncate the milliseconds part for a proper compare.
View Full Code Here

      if (redirectURL == null)
      {
        // No redirect; process the request
        ThreadContext.setApplication(application);

        WebRequest webRequest = application.createWebRequest(httpServletRequest, filterPath);
        WebResponse webResponse = application.createWebResponse(webRequest,
          httpServletResponse);

        RequestCycle requestCycle = application.createRequestCycle(webRequest, webResponse);
        if (!requestCycle.processRequestAndDetach())
View Full Code Here

      {
        servletRequest = factory.getWrapper(servletRequest);
      }
    }

    WebRequest webRequest = newWebRequest(servletRequest, filterPath);

    return webRequest;
  }
View Full Code Here

    {
      final RequestCycle cycle = RequestCycle.get();

      if (insert == false)
      {
        WebRequest request = (WebRequest)cycle.getRequest();

        String accept = request.getHeader("Accept");
        insert = ((accept == null) || (accept.indexOf(MarkupType.XML_MIME) != -1));
      }

      if (insert)
      {
View Full Code Here

    boolean isAjax = false;

    Request request = requestCycle.getRequest();
    if (request instanceof WebRequest)
    {
      WebRequest webRequest = (WebRequest)request;
      isAjax = webRequest.isAjax();
    }

    return isAjax;
  }
View Full Code Here

      {
        servletRequest = factory.getWrapper(servletRequest);
      }
    }

    WebRequest webRequest = newWebRequest(servletRequest, filterPath);

    return webRequest;
  }
View Full Code Here

TOP

Related Classes of org.apache.wicket.request.http.WebRequest

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.