org.mule.routing
Class CompositeRoutingException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by org.mule.api.MuleException
              extended by org.mule.api.MessagingException
                  extended by org.mule.routing.CompositeRoutingException
All Implemented Interfaces:
Serializable

public class CompositeRoutingException
extends MessagingException

This is a MessagingException used to aggregate exceptions thrown by several routes in the context of a single MessageRouter Exceptions are correlated to each route through a sequential id

Since:
3.5.0
See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.mule.api.MessagingException
event, muleMessage, processedEvent
 
Constructor Summary
CompositeRoutingException(Message message, MuleEvent event, Map<Integer,Throwable> exceptions)
          Constructs a new CompositeRoutingException
CompositeRoutingException(MuleEvent event, Map<Integer,Throwable> exceptions)
           
 
Method Summary
 Throwable getExceptionForRouteIndex(Integer index)
          Returns the Exception for the given route index
 Map<Integer,Throwable> getExceptions()
           
 
Methods inherited from class org.mule.api.MessagingException
causedBy, causedExactlyBy, causedRollback, causeMatches, extractMuleMessage, getCauseException, getEvent, getFailingMessageProcessor, getMuleMessage, handled, setCauseRollback, setHandled, setProcessedEvent
 
Methods inherited from class org.mule.api.MuleException
addInfo, appendMessage, equals, getDetailedMessage, getExceptionCode, getI18nMessage, getInfo, getMessage, getMessageCode, getSummaryMessage, getVerboseMessage, hashCode, initialise, prependMessage, setExceptionCode, setMessage, setMessage
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CompositeRoutingException

public CompositeRoutingException(Message message,
                                 MuleEvent event,
                                 Map<Integer,Throwable> exceptions)
Constructs a new CompositeRoutingException

Parameters:
message - message describing the failure
event - the current MuleEvent
exceptions - a Map in which the key is an Integer describing the index of the route that generated the error and the value is the Throwable itself

CompositeRoutingException

public CompositeRoutingException(MuleEvent event,
                                 Map<Integer,Throwable> exceptions)
Method Detail

getExceptionForRouteIndex

public Throwable getExceptionForRouteIndex(Integer index)
Returns the Exception for the given route index

Parameters:
index - the index of a failing route
Returns:
an Exception or null if no Exception was found for that index

getExceptions

public Map<Integer,Throwable> getExceptions()
Returns:
a Map in which the key is an Integer describing the number of the route that generated the error and the value is the Exception itself


Copyright © 2003-2014 MuleSoft, Inc.. All Rights Reserved.