Oracle8i Application Developer's Guide - Advanced Queuing Release 2 (8.1.6) Part Number A76938-01 |
|
JMS Operational Interface: Basic Operations (Point-to-Point), 11 of 22
Send a message using a queue sender with default send options.
If the QueueSender has been created with a default queue, then the queue parameter may not necessarily be supplied in the send call. If a queue is specified in the send operation, then this value will override the default queue of the QueueSender.
If the QueueSender has been created without a default queue, then the queue parameter must be specified in every send call.
This send operation uses default values for message priority (1) and timeToLive (infinite).
/* Create a sender to send messages to any queue */ QueueSession jms_sess; QueueSender sender1; TextMessage message; sender1 = jms_sess.createSender(null); sender1.send(queue, message);
/* Create a sender to send messages to a specific queue */ QueueSession jms_sess; QueueSender sender2; Queue billed_orders_que; TextMessage message; sender2 = jms_sess.createSender(billed_orders_que); sender2.send(queue, message);
|
![]() Copyright © 1996-2000, Oracle Corporation. All Rights Reserved. |
|