public class MessagingException extends MuleException
MessagingException
is a general message exception thrown when errors
specific to Message processing occur..Modifier and Type | Field and Description |
---|---|
protected MuleEvent |
event
The MuleEvent being processed when the error occurred
|
protected MuleMessage |
muleMessage
The MuleMessage being processed when the error occurred
|
protected MuleEvent |
processedEvent |
Constructor and Description |
---|
MessagingException(Message message,
MuleEvent event) |
MessagingException(Message message,
MuleEvent event,
MessageProcessor failingMessageProcessor) |
MessagingException(Message message,
MuleEvent event,
Throwable cause) |
MessagingException(Message message,
MuleEvent event,
Throwable cause,
MessageProcessor failingMessageProcessor) |
MessagingException(Message message,
MuleMessage muleMessage)
Deprecated.
use MessagingException(Message, MuleEvent)
|
MessagingException(Message message,
MuleMessage muleMessage,
Throwable cause)
Deprecated.
use MessagingException(Message, MuleEvent, Throwable)
|
MessagingException(MuleEvent event,
Throwable cause) |
MessagingException(MuleEvent event,
Throwable cause,
MessageProcessor failingMessageProcessor) |
Modifier and Type | Method and Description |
---|---|
boolean |
causedBy(Class e)
Evaluates if the exception was caused (instance of) by the provided exception
type
|
boolean |
causedExactlyBy(Class e)
Evaluates if the exception was caused by the type and only the type provided
exception type i,e: if cause exception is NullPointerException will only
return true if provided exception type is NullPointerException
|
boolean |
causedRollback()
Signals if the exception cause rollback of any current transaction if any or
if the message source should rollback incoming message
|
boolean |
causeMatches(String regex)
Checks the cause exception type name matches the provided regex.
|
protected void |
extractMuleMessage(MuleEvent event) |
protected String |
generateMessage(Message message) |
Exception |
getCauseException() |
MuleEvent |
getEvent() |
MessageProcessor |
getFailingMessageProcessor() |
MuleMessage |
getMuleMessage()
Deprecated.
use
#getEvent().getMessage() instead |
boolean |
handled()
Signals if exception has been handled or not
|
void |
setCauseRollback(boolean causeRollback)
Marks exception as rollback cause.
|
void |
setHandled(boolean handled)
Marks an exception as handled so it won't be re-throwed
|
void |
setProcessedEvent(MuleEvent processedEvent)
Sets the event that should be processed once this exception is caught
|
addInfo, appendMessage, equals, getDetailedMessage, getExceptionCode, getI18nMessage, getInfo, getMessage, getMessageCode, getSummaryMessage, getVerboseMessage, hashCode, initialise, prependMessage, setExceptionCode, setMessage, setMessage
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
protected transient MuleMessage muleMessage
protected final transient MuleEvent event
protected transient MuleEvent processedEvent
@Deprecated public MessagingException(Message message, MuleMessage muleMessage)
public MessagingException(Message message, MuleEvent event, MessageProcessor failingMessageProcessor)
@Deprecated public MessagingException(Message message, MuleMessage muleMessage, Throwable cause)
public MessagingException(Message message, MuleEvent event, Throwable cause, MessageProcessor failingMessageProcessor)
public MessagingException(MuleEvent event, Throwable cause, MessageProcessor failingMessageProcessor)
@Deprecated public MuleMessage getMuleMessage()
#getEvent().getMessage()
insteadpublic MuleEvent getEvent()
public void setProcessedEvent(MuleEvent processedEvent)
processedEvent
- event bounded to the exceptionpublic boolean causedBy(Class e)
e
- exception type to check againstpublic boolean causedExactlyBy(Class e)
e
- exception type to check againstpublic Exception getCauseException()
public boolean causeMatches(String regex)
regex
- regular expression to match against the exception type namepublic boolean causedRollback()
public void setCauseRollback(boolean causeRollback)
causeRollback
- public void setHandled(boolean handled)
handled
- true if the exception must be mark as handled, false otherwisepublic boolean handled()
public MessageProcessor getFailingMessageProcessor()
protected void extractMuleMessage(MuleEvent event)
Copyright © 2003–2015 MuleSoft, Inc.. All rights reserved.