RichFaces Showcase 4.2.0.Final

org.richfaces.demo.push
Class TopicsContextMessageProducer

java.lang.Object
  extended by org.richfaces.demo.push.TopicsContextMessageProducer
All Implemented Interfaces:
MessageProducer

public class TopicsContextMessageProducer
extends Object
implements MessageProducer

Sends message to topic using TopicsContext.

Author:
Lukas Fryc

Field Summary
static String PUSH_TOPICS_CONTEXT_TOPIC
           
 
Constructor Summary
TopicsContextMessageProducer()
           
 
Method Summary
 void finalizeProducer()
          Finalizes the producer (frees all associated resources)
 int getInterval()
          Interval which will be producer sleeping after last message sent before start of sending of next message.
 void sendMessage()
          Sends a message.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PUSH_TOPICS_CONTEXT_TOPIC

public static final String PUSH_TOPICS_CONTEXT_TOPIC
See Also:
Constant Field Values
Constructor Detail

TopicsContextMessageProducer

public TopicsContextMessageProducer()
Method Detail

sendMessage

public void sendMessage()
                 throws Exception
Description copied from interface: MessageProducer
Sends a message.

Specified by:
sendMessage in interface MessageProducer
Throws:
Exception - any exception which was thrown when trying to send message.

getInterval

public int getInterval()
Description copied from interface: MessageProducer
Interval which will be producer sleeping after last message sent before start of sending of next message.

Specified by:
getInterval in interface MessageProducer
Returns:
interval in miliseconds

finalizeProducer

public void finalizeProducer()
Description copied from interface: MessageProducer
Finalizes the producer (frees all associated resources)

Specified by:
finalizeProducer in interface MessageProducer

RichFaces Showcase 4.2.0.Final

Copyright © 2012 JBoss by Red Hat. All Rights Reserved.