Package org.apache.wicket.protocol.http

Examples of org.apache.wicket.protocol.http.WebApplication


   * @since 6.0
   */
  protected final AjaxRequestAttributes getAttributes()
  {
    AjaxRequestAttributes attributes = new AjaxRequestAttributes();
    WebApplication application = (WebApplication) getComponent().getApplication();
    AjaxRequestTargetListenerCollection ajaxRequestTargetListeners = application.getAjaxRequestTargetListeners();
    for (AjaxRequestTarget.IListener listener : ajaxRequestTargetListeners)
    {
      if (listener instanceof AjaxRequestTarget.AbstractListener)
      {
        ((AjaxRequestTarget.AbstractListener) listener).updateAjaxAttributes(attributes);
View Full Code Here


   * @see org.apache.wicket.behavior.IBehaviorListener#onRequest()
   */
  @Override
  public final void onRequest()
  {
    WebApplication app = (WebApplication)getComponent().getApplication();
    AjaxRequestTarget target = app.newAjaxRequestTarget(getComponent().getPage());

    RequestCycle requestCycle = RequestCycle.get();
    requestCycle.scheduleRequestHandlerAfterCurrent(target);

    respond(target);
View Full Code Here

    }

    String key = req.getHeader("Sec-WebSocket-Key");
    resp.setHeader("Sec-WebSocket-Accept", getWebSocketAccept(key));

    WebApplication application = getApplication();
    // Small hack until the Servlet API provides a way to do this.
    TomcatWebSocketProcessor webSocketHandler = new TomcatWebSocketProcessor(req, application);
    TomcatWebSocketProcessor.TomcatWebSocket tomcatWebSocket = webSocketHandler.new TomcatWebSocket();

    // the request can be a wrapper from application servlet filters
View Full Code Here

   * @see org.apache.wicket.behavior.IBehaviorListener#onRequest()
   */
  @Override
  public final void onRequest()
  {
    WebApplication app = (WebApplication)getComponent().getApplication();
    AjaxRequestTarget target = app.newAjaxRequestTarget(getComponent().getPage());

    RequestCycle requestCycle = RequestCycle.get();
    requestCycle.scheduleRequestHandlerAfterCurrent(target);

    respond(target);
View Full Code Here

  public void commonBefore()
  {
    // make sure no leaked threadlocals are present
    ThreadContext.detach();

    WebApplication application = newApplication();
    tester = newWicketTester(application);
  }
View Full Code Here

   * https://issues.apache.org/jira/browse/WICKET-5560
   */
  @Test
  public void enforceMountsWithCryptoMapper()
  {
      WebApplication app = tester.getApplication();
      app.setRootRequestMapper(new CryptoMapper(app.getRootRequestMapper(), app));
      enforceMounts();
  }
View Full Code Here

public class GlobalUpdateAjaxAttributesTest extends WicketTestCase
{
  @Override
  protected WebApplication newApplication()
  {
    WebApplication application = super.newApplication();
    application.getAjaxRequestTargetListeners().add(new AjaxRequestTarget.AbstractListener()
    {
      @Override
      public void updateAjaxAttributes(Behavior behavior, AjaxRequestAttributes attributes)
      {
        super.updateAjaxAttributes(behavior, attributes);
View Full Code Here

{

  @Override
  protected WebApplication newApplication()
  {
    WebApplication webApplication = new MockApplication()
    {
      @Override
      protected void init()
      {
        super.init();
View Full Code Here

   * @since 6.0
   */
  protected final AjaxRequestAttributes getAttributes()
  {
    AjaxRequestAttributes attributes = new AjaxRequestAttributes();
    WebApplication application = (WebApplication)getComponent().getApplication();
    AjaxRequestTargetListenerCollection ajaxRequestTargetListeners = application
      .getAjaxRequestTargetListeners();
    for (AjaxRequestTarget.IListener listener : ajaxRequestTargetListeners)
    {
      listener.updateAjaxAttributes(this, attributes);
    }
View Full Code Here

   * @see org.apache.wicket.behavior.IBehaviorListener#onRequest()
   */
  @Override
  public final void onRequest()
  {
    WebApplication app = (WebApplication)getComponent().getApplication();
    AjaxRequestTarget target = app.newAjaxRequestTarget(getComponent().getPage());

    RequestCycle requestCycle = RequestCycle.get();
    requestCycle.scheduleRequestHandlerAfterCurrent(target);

    respond(target);
View Full Code Here

TOP

Related Classes of org.apache.wicket.protocol.http.WebApplication

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.