org.nuxeo.ecm.core.jms
Class MessagePublisher
java.lang.Object
org.nuxeo.ecm.core.jms.MessagePublisher
public class MessagePublisher
- extends Object
This object is not thread safe. Should be used only in a single thread
- Author:
- Bogdan Stefanescu
MessagePublisher
public MessagePublisher(Topic topic,
TopicConnectionFactory factory)
MessagePublisher
public MessagePublisher(Topic topic,
TopicConnectionFactory factory,
MessageFactory messageFactory)
getTopic
public Topic getTopic()
setTopic
public void setTopic(Topic topic)
setMessageFactory
public void setMessageFactory(MessageFactory factory)
getMessageFactory
public MessageFactory getMessageFactory()
getConnection
public TopicConnection getConnection()
throws JMSException
- Throws:
JMSException
getSession
public TopicSession getSession()
throws JMSException
- Throws:
JMSException
getPublisher
public TopicPublisher getPublisher()
throws JMSException
- Throws:
JMSException
publish
public void publish(Object content)
throws JMSException
- Throws:
JMSException
publish
public void publish(Message msg)
throws JMSException
- Throws:
JMSException
close
public void close()
throws JMSException
- Throws:
JMSException
createPublisher
public static MessagePublisher createPublisher(String connectionFactory,
String topic)
throws NamingException
- Throws:
NamingException
createPublisher
public static MessagePublisher createPublisher(String connectionFactoryName,
String topicName,
MessageFactory messageFactory)
throws NamingException
- Throws:
NamingException
Copyright © 2011 Nuxeo SAS. All Rights Reserved.