com.sssw.jms.api
Class JMQMessageNotDeliveredException
java.lang.Object
java.lang.Throwable
java.lang.Exception
javax.jms.JMSException
com.sssw.jms.api.JMQMessageNotDeliveredException
- All Implemented Interfaces:
- Serializable
- public class JMQMessageNotDeliveredException
- extends JMSException
This exception is raised if a
MessageListener's
onMessage
method
continously raises an un-checked exception. Users should check for
this exception when JMS calls the connection's
ExceptionListener:
public void onException(JMSException ex)
{
if (ex instanceof JMQMessageNotDeliveredException)
{
JMQMessageNotDeliveredException mnde =
(JMQMessageNotDeliveredException) ex;
Message message = mnde.getJMSMessage();
// deal with message...
System.out.println("onMessage raised: " +
ex.getLinkedException());
}
else ...
}
- Since:
- jBroker MQ 1.3
- See Also:
- Serialized Form
Methods inherited from class java.lang.Throwable |
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString |
JMQMessageNotDeliveredException
public JMQMessageNotDeliveredException(String reason,
Message message)
- Construct a JMQMessageNotDeliveredException with reason and with error
code defaulting to null.
- Parameters:
reason
- a description of the exception.
JMQMessageNotDeliveredException
public JMQMessageNotDeliveredException(String reason,
String errCode,
Message message)
- Construct a JMQMessageNotDeliveredException with reason and errorCode
for exception.
- Parameters:
reason
- a description of the exception.errCode
- a string specifying the vendor specific error code.
getJMSMessage
public Message getJMSMessage()
- Get the message, which could not be delivered.
- Returns:
- a message which could not be delivered successfully via
the MessageListener's onMessage method.
exteNd is a registered trademark of Novell, Inc.
Copyright 1998-2004 Novell, Inc. All Rights Reserved.