org.atmosphere.jersey
Class Broadcastable

java.lang.Object
  extended by org.atmosphere.jersey.Broadcastable

public class Broadcastable
extends Object

Simple placeholder that can be used to broadcast message using a specific Broadcaster.

Author:
Jeanfrancois Arcand

Constructor Summary
Broadcastable(Broadcaster b)
           
Broadcastable(Object message, Broadcaster b)
          Broadcast the message to the set of suspended AtmosphereResource, and write back the message to the request which invoked the current resource method.
Broadcastable(Object message, Object callerMessage, Broadcaster b)
          Broadcast the message to the set of suspended AtmosphereResource, and write back the callerMessage to the request which invoked the current resource method.
 
Method Summary
 Object broadcast()
          Broadcast the message.
 Broadcaster getBroadcaster()
           
 Object getMessage()
           
 Object getResponseMessage()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Broadcastable

public Broadcastable(Broadcaster b)

Broadcastable

public Broadcastable(Object message,
                     Broadcaster b)
Broadcast the message to the set of suspended AtmosphereResource, and write back the message to the request which invoked the current resource method.

Parameters:
message - the message which will be broadcasted
b - the Broadcaster

Broadcastable

public Broadcastable(Object message,
                     Object callerMessage,
                     Broadcaster b)
Broadcast the message to the set of suspended AtmosphereResource, and write back the callerMessage to the request which invoked the current resource method.

Parameters:
message - the message which will be broadcasted
callerMessage - the message which will be sent back to the request.
b - the Broadcaster
Method Detail

broadcast

public Object broadcast()
Broadcast the message.

Returns:
the transformed message (BroadcastFilter)

getMessage

public Object getMessage()

getBroadcaster

public Broadcaster getBroadcaster()

getResponseMessage

public Object getResponseMessage()


Copyright © 2012. All Rights Reserved.