Package org.apache.wicket.ajax

Examples of org.apache.wicket.ajax.AbstractAjaxTimerBehavior


    add(prague);
    add(london);

    // add the timer behavior to the page and make it update all
    // other components as well
    final AbstractAjaxTimerBehavior timer = new AbstractAjaxTimerBehavior(Duration.seconds(1))
    {
      /**
       * @see org.apache.wicket.ajax.AbstractAjaxTimerBehavior#onTimer(org.apache.wicket.ajax.AjaxRequestTarget)
       */
      @Override
      protected void onTimer(AjaxRequestTarget target)
      {
        target.add(la);
        target.add(ny);
        target.add(moscow);
        target.add(prague);
        target.add(london);
      }
    };
    add(timer);

    add(new AjaxLink<Void>("stop")
    {

      @Override
      public void onClick(AjaxRequestTarget target)
      {
        timer.stop(target);
      }
    });

    add(new AjaxLink<Void>("restart")
    {

      @Override
      public void onClick(AjaxRequestTarget target)
      {
        timer.restart(target);
      }
    });
  }
View Full Code Here


      }
    });
    add(jsPlaceholder);

    add(new AjaxProofContainer("ajaxProofPlaceholder"));
    add(new AbstractAjaxTimerBehavior(Duration.seconds(4))
    {
      private static final long serialVersionUID = 1L;

      @Override
      protected void onTimer(AjaxRequestTarget target)
View Full Code Here

        {
          checkUsability(component, true);

          log.debug("Triggering AjaxSelfUpdatingTimerBehavior: " +
            component.getClassRelativePath());
          AbstractAjaxTimerBehavior timer = (AbstractAjaxTimerBehavior)b;
          if (!timer.isStopped())
          {
            executeBehavior(timer);
          }
        }
      }
View Full Code Here

          setVisible(model.isEnabled());
          timeRemainingLabel.setVisible(model.isEnabled());
        }
      }.setVisible(model.isEnabled()));

      add(new AbstractAjaxTimerBehavior(STEP_DURATION)
      {
        private static final long serialVersionUID = 1L;

        @Override
        protected void onTimer(AjaxRequestTarget target)
View Full Code Here

      }
    });
    add(jsPlaceholder);

    add(new AjaxProofContainer("ajaxProofPlaceholder"));
    add(new AbstractAjaxTimerBehavior(Duration.seconds(4))
    {
      private static final long serialVersionUID = 1L;

      @Override
      protected void onTimer(AjaxRequestTarget target)
View Full Code Here

  private void internalExecuteAllTimerBehaviors(final Component component)
  {
    List<IBehavior> behaviors = BehaviorsUtil.getBehaviors(component, AbstractAjaxTimerBehavior.class);
    for (IBehavior b : behaviors)
    {
      AbstractAjaxTimerBehavior timer = (AbstractAjaxTimerBehavior) b;
     
      if (!timer.isStopped())
      {
        if (log.isDebugEnabled())
        {
          log.debug("Triggering AjaxSelfUpdatingTimerBehavior: {}", component.getClassRelativePath());
        }
View Full Code Here

    add(prague);
    add(london);

    // add the timer behavior to the page and make it update all
    // other components as well
    add(new AbstractAjaxTimerBehavior(Duration.seconds(1))
    {
      /**
       * @see org.apache.wicket.ajax.AbstractAjaxTimerBehavior#onTimer(org.apache.wicket.ajax.AjaxRequestTarget)
       */
      @Override
 
View Full Code Here

      }
    });
    add(jsPlaceholder);

    add(new AjaxProofContainer("ajaxProofPlaceholder"));
    add(new AbstractAjaxTimerBehavior(Duration.seconds(4))
    {
      private static final long serialVersionUID = 1L;

      @Override
      protected void onTimer(AjaxRequestTarget target)
View Full Code Here

        {
          checkUsability(component, true);

          log.debug("Triggering AjaxSelfUpdatingTimerBehavior: " +
            component.getClassRelativePath());
          AbstractAjaxTimerBehavior timer = (AbstractAjaxTimerBehavior)b;
          if (!timer.isStopped())
          {
            executeBehavior(timer);
          }
        }
      }
View Full Code Here

        {
          checkUsability(component);

          log.debug("Triggering AjaxSelfUpdatingTimerBehavior: " +
            component.getClassRelativePath());
          AbstractAjaxTimerBehavior timer = (AbstractAjaxTimerBehavior)b;
          if (!timer.isStopped())
          {
            executeBehavior(timer);
          }
        }
      }
View Full Code Here

TOP

Related Classes of org.apache.wicket.ajax.AbstractAjaxTimerBehavior

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.