org.wicketstuff.push
Interface IChannelListener

All Superinterfaces:
java.util.EventListener, java.io.Serializable
All Known Implementing Classes:
DummyChannelListener

public interface IChannelListener
extends java.io.Serializable, java.util.EventListener

Implementations of this interface can be notified of events triggered by a IChannelPublisher

Implementation example:

        channelService.addChannelListener(this, "channel", new IChannelListener() {
                public void onEvent(String channel, Map datas, IChannelTarget target){
                        target.addComponent(aComponent);
                }
        });
 

Author:
Vincent Demay, Xavier Hanin
See Also:
IChannelService

Method Summary
 void onEvent(java.lang.String channel, java.util.Map<java.lang.String,java.lang.String> datas, IChannelTarget target)
          Method called when an event is triggered on a channel.
 

Method Detail

onEvent

void onEvent(java.lang.String channel,
             java.util.Map<java.lang.String,java.lang.String> datas,
             IChannelTarget target)
Method called when an event is triggered on a channel. Implementations usually use the IChannelTarget to update the web page according to the event triggered.

Parameters:
channel - channel which be used to listen to event
datas - data sent by the event
target - see IChannelTarget


Copyright © 2010. All Rights Reserved.