org.wicketstuff.push
Class JavaScriptChannelEvent
java.lang.Object
org.wicketstuff.push.ChannelEvent
org.wicketstuff.push.JavaScriptChannelEvent
public abstract class JavaScriptChannelEvent
- extends ChannelEvent
Usually on sending an event to a channel, the ChannelEvent invokes a javascript method on the
client which then starts an Ajax-request. In order to save the additional round-trip, this
class has been made. It executes the javascript-code returned by the getJavaScript()
method.
- Author:
- Michael Sparer (msparer)
|
Field Summary |
static java.lang.String |
KEY
Setting the event's name to this key makes the client side execute its value |
|
Method Summary |
protected abstract java.lang.String |
getJavaScript()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
KEY
public static final java.lang.String KEY
- Setting the event's name to this key makes the client side execute its value
- See Also:
- Constant Field Values
JavaScriptChannelEvent
public JavaScriptChannelEvent(java.lang.String channel)
- Parameters:
channel - the channel name
getJavaScript
protected abstract java.lang.String getJavaScript()
- Returns:
- javascript code that gets evaluated on the client without making a roundtrip
Copyright © 2010. All Rights Reserved.