org.wicketstuff.push
Class ChannelEvent

java.lang.Object
  extended by org.wicketstuff.push.ChannelEvent
Direct Known Subclasses:
CometdEvent, JavaScriptChannelEvent

public class ChannelEvent
extends java.lang.Object

A event containing data to send by server pushing. This event has to be published by IChannelPublisher instance.

a pushEvent is specific of a channel represented by a string and can contains some datas to send to the listener.

Author:
Vincent Demay, Rodolfo Hansen

Constructor Summary
ChannelEvent(java.lang.String channel)
          Construct.
 
Method Summary
 void addData(java.lang.String key, java.lang.String data)
          Add a data in the event.
 java.lang.String getChannel()
          return the channel of the event
 java.util.Map<java.lang.String,java.lang.String> getData()
          Returns all data in the event
 java.lang.String getId()
           
 void setChannel(java.lang.String channel)
          set the channel of the event
 void setId(java.lang.String id)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ChannelEvent

public ChannelEvent(java.lang.String channel)
Construct.

Parameters:
channel - channel where the event will be sent
Method Detail

getChannel

public java.lang.String getChannel()
return the channel of the event

Returns:
the channel of the event

setChannel

public void setChannel(java.lang.String channel)
set the channel of the event

Parameters:
channel - event channel

addData

public void addData(java.lang.String key,
                    java.lang.String data)
Add a data in the event. This event will be transfered to all the listener of the channel

Parameters:
key - data key
data - data to add in the event

getData

public java.util.Map<java.lang.String,java.lang.String> getData()
Returns all data in the event

Returns:
all data in the event

getId

public java.lang.String getId()

setId

public void setId(java.lang.String id)


Copyright © 2010. All Rights Reserved.