Class WmQueueSenderImpl

    • Method Detail

      • getQueue

        public javax.jms.Queue getQueue()
                                 throws javax.jms.JMSException
        Gets the queue associated with this QueueSender.
        Specified by:
        getQueue in interface javax.jms.QueueSender
        Returns:
        this sender's queue
        Throws:
        javax.jms.JMSException - if the JMS provider fails to get the queue for this QueueSender due to some internal error.
      • send

        public void send​(javax.jms.Queue queue,
                         javax.jms.Message message)
                  throws javax.jms.JMSException
        Sends a message to a queue for an unidentified message producer. Uses the QueueSender's default delivery mode, priority, and time to live.

        Typically, a message producer is assigned a queue at creation time; however, the JMS API also supports unidentified message producers, which require that the queue be supplied every time a message is sent.

        Specified by:
        send in interface javax.jms.QueueSender
        Parameters:
        queue - the queue to send this message to
        message - the message to send
        Throws:
        javax.jms.JMSException - if the JMS provider fails to send the message due to some internal error.
        javax.jms.MessageFormatException - if an invalid message is specified.
        javax.jms.InvalidDestinationException - if a client uses this method with an invalid queue.
        See Also:
        MessageProducer.getDeliveryMode(), MessageProducer.getTimeToLive(), MessageProducer.getPriority()
      • send

        public void send​(javax.jms.Queue queue,
                         javax.jms.Message message,
                         int deliveryMode,
                         int priority,
                         long timeToLive)
                  throws javax.jms.JMSException
        Sends a message to a queue for an unidentified message producer, specifying delivery mode, priority and time to live.

        Typically, a message producer is assigned a queue at creation time; however, the JMS API also supports unidentified message producers, which require that the queue be supplied every time a message is sent.

        Specified by:
        send in interface javax.jms.QueueSender
        Parameters:
        queue - the queue to send this message to
        message - the message to send
        deliveryMode - the delivery mode to use
        priority - the priority for this message
        timeToLive - the message's lifetime (in milliseconds)
        Throws:
        javax.jms.JMSException - if the JMS provider fails to send the message due to some internal error.
        javax.jms.MessageFormatException - if an invalid message is specified.
        javax.jms.InvalidDestinationException - if a client uses this method with an invalid queue.
      • send

        public void send​(javax.jms.Queue queue,
                         javax.jms.Message[] messages)
                  throws javax.jms.JMSException
        Sends multiple messages to a queue for an unidentified message producer. Uses the QueueSender's default delivery mode, priority, and time to live.

        Typically, a message producer is assigned a queue at creation time; however, the JMS API also supports unidentified message producers, which require that the queue be supplied every time a message is sent.

        Specified by:
        send in interface WmQueueSender
        Parameters:
        queue - the queue to send the messages to
        messages - the messages to send
        Throws:
        javax.jms.JMSException - if the JMS provider fails to send the message due to some internal error.
        javax.jms.MessageFormatException - if an invalid message is specified.
        javax.jms.InvalidDestinationException - if a client uses this method with an invalid queue.
        See Also:
        MessageProducer.getDeliveryMode(), MessageProducer.getTimeToLive(), MessageProducer.getPriority()
      • send

        public void send​(javax.jms.Queue queue,
                         javax.jms.Message[] messages,
                         int deliveryMode,
                         int priority,
                         long timeToLive)
                  throws javax.jms.JMSException
        Sends multiple messages to a queue for an unidentified message producer, specifying delivery mode, priority and time to live.

        Typically, a message producer is assigned a queue at creation time; however, the JMS API also supports unidentified message producers, which require that the queue be supplied every time a message is sent.

        Specified by:
        send in interface WmQueueSender
        Parameters:
        queue - the queue to send the messages to
        messages - the messages to send
        deliveryMode - the delivery mode to use
        priority - the priority for this message
        timeToLive - the message's lifetime (in milliseconds)
        Throws:
        javax.jms.JMSException - if the JMS provider fails to send the message due to some internal error.
        javax.jms.MessageFormatException - if an invalid message is specified.
        javax.jms.InvalidDestinationException - if a client uses this method with an invalid queue.