//
// JmsaQueueSession.java - JMS Adapter QueueSession
//

package nyangau.jmsadapter;

import javax.jms.*;

public class JmsaQueueSession extends JmsaSession implements QueueSession
  {
//...sJmsaQueueSession:2:
public JmsaQueueSession(QueueSession sess, JmsaConnection conn, FlowProcessor flowproc)
  { super(sess, conn, flowproc); }
//...e

//...screateDurableSubscriber \45\ forbidden:2:
public TopicSubscriber createDurableSubscriber(Topic topic, String name)
  throws JMSException
  { throw new javax.jms.IllegalStateException("forbidden by JMS spec"); }

public TopicSubscriber createDurableSubscriber(Topic topic, String name, String messageSelector, boolean noLocal)
  throws JMSException
  { throw new javax.jms.IllegalStateException("forbidden by JMS spec"); }
//...e
//...sunsubscribe             \45\ forbidden:2:
public void unsubscribe(String subscriptionName)
  throws JMSException
  { throw new javax.jms.IllegalStateException("forbidden by JMS spec"); }
//...e
//...screateTopic             \45\ forbidden:2:
public Topic createTopic(String topicName)
  throws JMSException
  { throw new javax.jms.IllegalStateException("forbidden by JMS spec"); }
//...e
//...screateTemporaryTopic    \45\ forbidden:2:
public TemporaryTopic createTemporaryTopic()
  throws JMSException
  { throw new javax.jms.IllegalStateException("forbidden by JMS spec"); }
//...e

//...screateSender:2:
public QueueSender createSender(Queue queue)
  throws JMSException
  {
  return new JmsaQueueSender(
    ((QueueSession)s).createSender( (Queue)(((JmsaQueue)queue).getDest()) ),
    queue,
    fp
    );
  }
//...e
//...screateReceiver:2:
public QueueReceiver createReceiver(Queue queue)
  throws JMSException
  {
  return new JmsaQueueReceiver(
    ((QueueSession)s).createReceiver( (Queue)(((JmsaQueue)queue).getDest()) ),
    fp
    );
  }

public QueueReceiver createReceiver(Queue queue, String messageSelector)
  throws JMSException
  {
  return new JmsaQueueReceiver(
    ((QueueSession)s).createReceiver( (Queue)(((JmsaQueue)queue).getDest()), messageSelector ),
    fp
    );
  }
//...e
  }
