1 28 29 package com.caucho.jms.session; 30 31 import javax.jms.JMSException ; 32 import javax.jms.Topic ; 33 import javax.jms.TopicPublisher ; 34 import javax.jms.TopicSession ; 35 import javax.jms.TopicSubscriber ; 36 37 40 public class TopicSessionImpl extends SessionImpl implements TopicSession { 41 public TopicSessionImpl(ConnectionImpl conn, 42 boolean isTransacted, int ackMode) 43 throws JMSException 44 { 45 super(conn, isTransacted, ackMode); 46 } 47 48 53 public TopicPublisher createPublisher(Topic topic) 54 throws JMSException 55 { 56 checkOpen(); 57 58 if (topic == null) 59 throw new NullPointerException (); 60 61 return new TopicPublisherImpl(this, topic); 62 } 63 64 69 public TopicSubscriber createSubscriber(Topic topic) 70 throws JMSException 71 { 72 checkOpen(); 73 74 return createSubscriber(topic, null, false); 75 } 76 77 84 public TopicSubscriber createSubscriber(Topic topic, 85 String messageSelector, 86 boolean noLocal) 87 throws JMSException 88 { 89 return (TopicSubscriber ) createConsumer(topic, messageSelector, noLocal); 90 } 91 } 92 | Popular Tags |