|
Oracle GlassFish(tm) Server Message Queue 5.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface CompletionListener
A CompletionListener
is implemented by the application and may
be specified when a message is sent asynchronously.
When the sending of the message is complete, the JMS provider notifies the
application by calling the onCompletion(Message)
method of the
specified completion listener. If the sending if the message fails for any
reason, and an exception cannot be thrown by the send
method,
then the JMS provider calls the onException(Exception)
method of
the specified completion listener.
MessageProducer.send(javax.jms.Message,int,int,long,javax.jms.CompletionListener)
,
MessageProducer.send(javax.jms.Destination,javax.jms.Message,javax.jms.CompletionListener)
,
MessageProducer.send(javax.jms.Destination,javax.jms.Message,int,int,long,javax.jms.CompletionListener)
,
JMSProducer.setAsync(javax.jms.CompletionListener)
,
JMSProducer.getAsync()
Method Summary | |
---|---|
void |
onCompletion(Message message)
Notifies the application that the message has been successfully sent |
void |
onException(Message message,
java.lang.Exception exception)
Notifies user that the specified exception was thrown while attempting to send the specified message. |
Method Detail |
---|
void onCompletion(Message message)
message
- the message that was sent.void onException(Message message, java.lang.Exception exception)
message
- the message that was sent.exception
- the exception
|
Oracle GlassFish(tm) Server Message Queue 5.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |