org.apache.wicket.extensions.ajax.markup.html
Class AjaxIndicatorAppender

java.lang.Object
  extended by org.apache.wicket.behavior.Behavior
      extended by org.apache.wicket.extensions.ajax.markup.html.AjaxIndicatorAppender
All Implemented Interfaces:
Serializable, IComponentAwareEventSink, IComponentAwareHeaderContributor, org.apache.wicket.util.io.IClusterable

public class AjaxIndicatorAppender
extends Behavior

A behavior that adds a span with wicket's default indicator gif to the end of the component's markup. This span can be used as an ajax busy indicator. For an example usage see IndicatingAjaxLink

Instances of this behavior must not be shared between components.

Since:
1.2
Author:
Igor Vaynberg (ivaynberg)
See Also:
IndicatingAjaxLink, IAjaxIndicatorAware, Serialized Form

Constructor Summary
AjaxIndicatorAppender()
          Construct.
 
Method Summary
 void afterRender(Component component)
           
 void bind(Component component)
           
protected  CharSequence getIndicatorUrl()
           
 String getMarkupId()
          Returns the markup id attribute of the outer most span of this indicator.
protected  String getSpanClass()
           
 void renderHead(Component component, IHeaderResponse response)
           
 
Methods inherited from class org.apache.wicket.behavior.Behavior
beforeRender, canCallListenerInterface, detach, getStatelessHint, isEnabled, isTemporary, onComponentTag, onConfigure, onEvent, onException, onRemove, unbind
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AjaxIndicatorAppender

public AjaxIndicatorAppender()
Construct.

Method Detail

renderHead

public void renderHead(Component component,
                       IHeaderResponse response)
Specified by:
renderHead in interface IComponentAwareHeaderContributor
Overrides:
renderHead in class Behavior

afterRender

public void afterRender(Component component)
Overrides:
afterRender in class Behavior

getIndicatorUrl

protected CharSequence getIndicatorUrl()
Returns:
url of the animated indicator image

getSpanClass

protected String getSpanClass()
Returns:
css class name of the generated outer span

getMarkupId

public String getMarkupId()
Returns the markup id attribute of the outer most span of this indicator. This is the id of the span that should be hidden or show to hide or show the indicator.

Returns:
markup id of outer most span

bind

public final void bind(Component component)
Overrides:
bind in class Behavior
See Also:
Behavior.bind(org.apache.wicket.Component)


Copyright © 2006-2013 Apache Software Foundation. All Rights Reserved.