org.wicketstuff.push.timer
Class TimerChannelBehavior.TimerPushTarget

java.lang.Object
  extended by org.wicketstuff.push.timer.TimerChannelBehavior.TimerPushTarget
All Implemented Interfaces:
IChannelTarget, IPushTarget
Enclosing class:
TimerChannelBehavior

public static class TimerChannelBehavior.TimerPushTarget
extends java.lang.Object
implements IPushTarget

An IPushTarget implementation which enqueue DelayedMethodCallList, also called triggers, for a TimerChannelBehavior identified by its id. TimerPushTarget are thread safe, and can be used from any thread. Since it is not serializable, it is not intended to be stored in a wicket component.

Author:
Xavier Hanin

Constructor Summary
TimerChannelBehavior.TimerPushTarget(org.apache.wicket.Application application, java.lang.String id, org.apache.wicket.util.time.Duration timeout)
           
 
Method Summary
 void addComponent(org.apache.wicket.Component component)
          Adds a component to the list of components to be rendered
 void addComponent(org.apache.wicket.Component component, java.lang.String markupId)
          Adds a component to the list of components to be rendered
 void appendJavascript(java.lang.String javascript)
          Adds javascript that will be evaluated on the client side after components are replaced
 void focusComponent(org.apache.wicket.Component component)
          Sets the focus in the browser to the given component.
 boolean isConnected()
           
 void prependJavascript(java.lang.String javascript)
          Adds javascript that will be evaluated on the client side before components are replaced
 void trigger()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TimerChannelBehavior.TimerPushTarget

public TimerChannelBehavior.TimerPushTarget(org.apache.wicket.Application application,
                                            java.lang.String id,
                                            org.apache.wicket.util.time.Duration timeout)
Method Detail

addComponent

public void addComponent(org.apache.wicket.Component component)
Description copied from interface: IChannelTarget
Adds a component to the list of components to be rendered

Specified by:
addComponent in interface IChannelTarget
Parameters:
component - component to be rendered
See Also:
IAjaxPushBehavior#addComponent(Component)

addComponent

public void addComponent(org.apache.wicket.Component component,
                         java.lang.String markupId)
Description copied from interface: IChannelTarget
Adds a component to the list of components to be rendered

Specified by:
addComponent in interface IChannelTarget
Parameters:
component - component to be rendered
markupId - id of client-side dom element that will be updated
See Also:
IAjaxPushBehavior#addComponent(Component, String)

appendJavascript

public void appendJavascript(java.lang.String javascript)
Description copied from interface: IChannelTarget
Adds javascript that will be evaluated on the client side after components are replaced

Specified by:
appendJavascript in interface IChannelTarget
See Also:
IAjaxPushBehavior#appendJavascript(String)

focusComponent

public void focusComponent(org.apache.wicket.Component component)
Description copied from interface: IChannelTarget
Sets the focus in the browser to the given component. The markup id must be set.

Specified by:
focusComponent in interface IChannelTarget
Parameters:
component - The component to get the focus.
See Also:
IAjaxPushBehavior#focusComponent(Component)

prependJavascript

public void prependJavascript(java.lang.String javascript)
Description copied from interface: IChannelTarget
Adds javascript that will be evaluated on the client side before components are replaced

Specified by:
prependJavascript in interface IChannelTarget
See Also:
IAjaxPushBehavior#prependJavascript(String)

trigger

public void trigger()
Specified by:
trigger in interface IPushTarget
See Also:
IAjaxPushBehavior#trigger()

isConnected

public boolean isConnected()
Specified by:
isConnected in interface IPushTarget


Copyright © 2010. All Rights Reserved.