org.mule.tck.testmodels.mule
Class TestExceptionStrategy

java.lang.Object
  extended by org.mule.processor.AbstractMuleObjectOwner<MessageProcessor>
      extended by org.mule.processor.AbstractMessageProcessorOwner
          extended by org.mule.exception.AbstractExceptionListener
              extended by org.mule.tck.testmodels.mule.TestExceptionStrategy
All Implemented Interfaces:
AnnotatedObject, FlowConstructAware, MuleContextAware, ExceptionHandler, MessagingExceptionHandler, SystemExceptionHandler, Disposable, Initialisable, Lifecycle, Startable, Stoppable

public class TestExceptionStrategy
extends AbstractExceptionListener
implements MessagingExceptionHandler, SystemExceptionHandler

TestExceptionStrategy is used by the Mule test cases as a direct replacement of the AbstractMessagingExceptionStrategy. This is used to test that overriding the default Exception strategy works.


Nested Class Summary
static interface TestExceptionStrategy.ExceptionCallback
           
 
Field Summary
protected  Log logger
          logger used by this class
 
Fields inherited from class org.mule.exception.AbstractExceptionListener
commitTxFilter, enableNotifications, initialised, messageProcessors, rollbackTxFilter
 
Fields inherited from class org.mule.processor.AbstractMuleObjectOwner
flowConstruct, muleContext
 
Fields inherited from interface org.mule.api.lifecycle.Initialisable
PHASE_NAME
 
Fields inherited from interface org.mule.api.lifecycle.Startable
PHASE_NAME
 
Fields inherited from interface org.mule.api.lifecycle.Stoppable
PHASE_NAME
 
Fields inherited from interface org.mule.api.lifecycle.Disposable
PHASE_NAME
 
Fields inherited from interface org.mule.api.AnnotatedObject
PROPERTY_NAME
 
Constructor Summary
TestExceptionStrategy()
           
 
Method Summary
 String getTestProperty()
           
 void handleException(Exception exception)
           
 MuleEvent handleException(Exception exception, MuleEvent event)
           
 MuleEvent handleException(Exception exception, MuleEvent event, RollbackSourceCallback rollbackMethod)
           
 void handleException(Exception exception, RollbackSourceCallback rollbackMethod)
           
protected  void processUnhandled()
           
 void setExceptionCallback(TestExceptionStrategy.ExceptionCallback exceptionCallback)
           
 void setTestProperty(String testProperty)
           
 
Methods inherited from class org.mule.exception.AbstractExceptionListener
addEndpoint, closeStream, commit, doInitialise, fireNotification, fireNotification, getCommitTxFilter, getExceptionType, getMessageProcessors, getOwnedMessageProcessors, getRollbackTxFilter, handleTransaction, initialise, isEnableNotifications, isInitialised, isRollback, logException, logFatal, removeMessageProcessor, rollback, rollback, rollbackTransaction, routeException, routeException, setCommitTxFilter, setEnableNotifications, setMessageProcessors, setRollbackTxFilter
 
Methods inherited from class org.mule.processor.AbstractMessageProcessorOwner
getAnnotation, getAnnotations, getOwnedObjects, setAnnotations
 
Methods inherited from class org.mule.processor.AbstractMuleObjectOwner
dispose, getFlowConstruct, getMuleContext, setFlowConstruct, setMuleContext, start, stop
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.mule.api.lifecycle.Startable
start
 
Methods inherited from interface org.mule.api.lifecycle.Stoppable
stop
 
Methods inherited from interface org.mule.api.lifecycle.Disposable
dispose
 
Methods inherited from interface org.mule.api.context.MuleContextAware
setMuleContext
 
Methods inherited from interface org.mule.api.construct.FlowConstructAware
setFlowConstruct
 

Field Detail

logger

protected final Log logger
logger used by this class

Constructor Detail

TestExceptionStrategy

public TestExceptionStrategy()
Method Detail

getTestProperty

public String getTestProperty()

setTestProperty

public void setTestProperty(String testProperty)

handleException

public MuleEvent handleException(Exception exception,
                                 MuleEvent event,
                                 RollbackSourceCallback rollbackMethod)

handleException

public MuleEvent handleException(Exception exception,
                                 MuleEvent event)
Specified by:
handleException in interface MessagingExceptionHandler

handleException

public void handleException(Exception exception,
                            RollbackSourceCallback rollbackMethod)
Specified by:
handleException in interface SystemExceptionHandler

handleException

public void handleException(Exception exception)
Specified by:
handleException in interface SystemExceptionHandler

setExceptionCallback

public void setExceptionCallback(TestExceptionStrategy.ExceptionCallback exceptionCallback)

processUnhandled

protected void processUnhandled()


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