net.sf.excha.foo
Class MethodAnnotatedFooImpl

java.lang.Object
  extended by net.sf.excha.foo.MethodAnnotatedFooImpl
All Implemented Interfaces:
MethodAnnotatedFoo

public class MethodAnnotatedFooImpl
extends java.lang.Object
implements MethodAnnotatedFoo


Field Summary
 
Fields inherited from interface net.sf.excha.foo.MethodAnnotatedFoo
DELAY_BEFORE_RETRY, EXCEPTION_MESSAGE, ORIGIN_MESSAGE
 
Constructor Summary
MethodAnnotatedFooImpl()
           
 
Method Summary
 void doNotSubstituteDerivedFromIOException()
           
 void handledByCustomExeptionHandler()
           
 boolean handledByCustomExeptionHandlerReturningAValue()
           
 java.lang.Boolean handledByDoNothingExceptionHandler()
           
 void noSubstituteExceptionDefinded()
           
 void noSubstituteExceptionDefindedHandledBySuppress()
           
 void notAnnotatedMethodThrowsIOExceptionThatMustBeSubstitutedByRuntimeException()
           
 void notHandledByCustomExeptionHandler()
           
 void notThrowingException()
           
 void substituteDefault()
           
 void substituteDoNotWrapCauseUsingExceptionWithoutStringConstructor()
           
 void substituteDoNotWrapTryInsertMessageToNoStringConstructor()
           
 void substituteExectyIOException()
           
 void substituteIOException()
           
 void substituteKeepMessage()
           
 void substituteWithIllegalException()
           
 void substituteWithLegalNotRuntimeException()
           
 void substituteWithMessage()
           
 void substituteWithMessageWithSubstituteWithoutConstructorForString()
           
 void substituteWithSubstituteWithoutConstructorForString()
           
 void substituteWrapCause()
           
 void substituteWrapCauseAndSubstituteWithoutConstructorForString()
           
 void substituteWrapCauseAndSubstituteWithoutConstructorForStringTryingToKeepOriginalMethod()
           
 java.lang.String swallowException()
           
 java.lang.String testingDoNotHandleThrowsSocketExceptionExpectedRuntimeException()
           
 java.lang.String testingDoNotHandleThrowsSocketExceptionExpectedSocketException()
           
 void throwsExceptionEachTimeItIsCalled()
           
 void throwsExceptionEachTimeItIsCalledWeExcpectRetriesWithDelay()
           
 void throwsExceptionOnlyOnFirstCall()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MethodAnnotatedFooImpl

public MethodAnnotatedFooImpl()
Method Detail

notAnnotatedMethodThrowsIOExceptionThatMustBeSubstitutedByRuntimeException

public void notAnnotatedMethodThrowsIOExceptionThatMustBeSubstitutedByRuntimeException()
                                                                                throws java.io.IOException
Specified by:
notAnnotatedMethodThrowsIOExceptionThatMustBeSubstitutedByRuntimeException in interface MethodAnnotatedFoo
Throws:
java.io.IOException

substituteDefault

public void substituteDefault()
                       throws java.lang.Exception
Specified by:
substituteDefault in interface MethodAnnotatedFoo
Throws:
java.lang.Exception

substituteWrapCause

public void substituteWrapCause()
                         throws java.lang.Exception
Specified by:
substituteWrapCause in interface MethodAnnotatedFoo
Throws:
java.lang.Exception

substituteWrapCauseAndSubstituteWithoutConstructorForString

public void substituteWrapCauseAndSubstituteWithoutConstructorForString()
                                                                 throws java.lang.Exception
Specified by:
substituteWrapCauseAndSubstituteWithoutConstructorForString in interface MethodAnnotatedFoo
Throws:
java.lang.Exception

substituteWrapCauseAndSubstituteWithoutConstructorForStringTryingToKeepOriginalMethod

public void substituteWrapCauseAndSubstituteWithoutConstructorForStringTryingToKeepOriginalMethod()
                                                                                           throws java.lang.Exception
Specified by:
substituteWrapCauseAndSubstituteWithoutConstructorForStringTryingToKeepOriginalMethod in interface MethodAnnotatedFoo
Throws:
java.lang.Exception

substituteDoNotWrapCauseUsingExceptionWithoutStringConstructor

public void substituteDoNotWrapCauseUsingExceptionWithoutStringConstructor()
                                                                    throws java.lang.Exception
Specified by:
substituteDoNotWrapCauseUsingExceptionWithoutStringConstructor in interface MethodAnnotatedFoo
Throws:
java.lang.Exception

substituteDoNotWrapTryInsertMessageToNoStringConstructor

public void substituteDoNotWrapTryInsertMessageToNoStringConstructor()
                                                              throws java.lang.Exception
Specified by:
substituteDoNotWrapTryInsertMessageToNoStringConstructor in interface MethodAnnotatedFoo
Throws:
java.lang.Exception

substituteWithMessage

public void substituteWithMessage()
                           throws java.lang.Exception
Specified by:
substituteWithMessage in interface MethodAnnotatedFoo
Throws:
java.lang.Exception

substituteWithMessageWithSubstituteWithoutConstructorForString

public void substituteWithMessageWithSubstituteWithoutConstructorForString()
                                                                    throws java.lang.Exception
Specified by:
substituteWithMessageWithSubstituteWithoutConstructorForString in interface MethodAnnotatedFoo
Throws:
java.lang.Exception

substituteWithSubstituteWithoutConstructorForString

public void substituteWithSubstituteWithoutConstructorForString()
                                                         throws java.lang.Exception
Specified by:
substituteWithSubstituteWithoutConstructorForString in interface MethodAnnotatedFoo
Throws:
java.lang.Exception

substituteKeepMessage

public void substituteKeepMessage()
                           throws java.lang.Exception
Specified by:
substituteKeepMessage in interface MethodAnnotatedFoo
Throws:
java.lang.Exception

substituteIOException

public void substituteIOException()
                           throws java.io.IOException
Specified by:
substituteIOException in interface MethodAnnotatedFoo
Throws:
java.io.IOException

substituteExectyIOException

public void substituteExectyIOException()
                                 throws java.io.IOException
Specified by:
substituteExectyIOException in interface MethodAnnotatedFoo
Throws:
java.io.IOException

doNotSubstituteDerivedFromIOException

public void doNotSubstituteDerivedFromIOException()
                                           throws java.io.IOException
Specified by:
doNotSubstituteDerivedFromIOException in interface MethodAnnotatedFoo
Throws:
java.io.IOException

substituteWithLegalNotRuntimeException

public void substituteWithLegalNotRuntimeException()
                                            throws java.io.IOException
Specified by:
substituteWithLegalNotRuntimeException in interface MethodAnnotatedFoo
Throws:
java.io.IOException

substituteWithIllegalException

public void substituteWithIllegalException()
                                    throws java.net.SocketException
Specified by:
substituteWithIllegalException in interface MethodAnnotatedFoo
Throws:
java.net.SocketException

swallowException

public java.lang.String swallowException()
                                  throws java.io.IOException
Specified by:
swallowException in interface MethodAnnotatedFoo
Throws:
java.io.IOException

testingDoNotHandleThrowsSocketExceptionExpectedSocketException

public java.lang.String testingDoNotHandleThrowsSocketExceptionExpectedSocketException()
                                                                                throws java.io.IOException
Specified by:
testingDoNotHandleThrowsSocketExceptionExpectedSocketException in interface MethodAnnotatedFoo
Throws:
java.io.IOException

testingDoNotHandleThrowsSocketExceptionExpectedRuntimeException

public java.lang.String testingDoNotHandleThrowsSocketExceptionExpectedRuntimeException()
                                                                                 throws java.io.IOException
Specified by:
testingDoNotHandleThrowsSocketExceptionExpectedRuntimeException in interface MethodAnnotatedFoo
Throws:
java.io.IOException

notThrowingException

public void notThrowingException()
Specified by:
notThrowingException in interface MethodAnnotatedFoo

notHandledByCustomExeptionHandler

public void notHandledByCustomExeptionHandler()
                                       throws java.io.IOException
Specified by:
notHandledByCustomExeptionHandler in interface MethodAnnotatedFoo
Throws:
java.io.IOException

handledByCustomExeptionHandler

public void handledByCustomExeptionHandler()
                                    throws ExceptionWithoutStringConstructor
Specified by:
handledByCustomExeptionHandler in interface MethodAnnotatedFoo
Throws:
ExceptionWithoutStringConstructor

handledByCustomExeptionHandlerReturningAValue

public boolean handledByCustomExeptionHandlerReturningAValue()
                                                      throws ExceptionWithoutStringConstructor
Specified by:
handledByCustomExeptionHandlerReturningAValue in interface MethodAnnotatedFoo
Throws:
ExceptionWithoutStringConstructor

handledByDoNothingExceptionHandler

public java.lang.Boolean handledByDoNothingExceptionHandler()
                                                     throws ExceptionWithoutStringConstructor
Specified by:
handledByDoNothingExceptionHandler in interface MethodAnnotatedFoo
Throws:
ExceptionWithoutStringConstructor

noSubstituteExceptionDefinded

public void noSubstituteExceptionDefinded()
                                   throws ErrorCodeException
Specified by:
noSubstituteExceptionDefinded in interface MethodAnnotatedFoo
Throws:
ErrorCodeException

noSubstituteExceptionDefindedHandledBySuppress

public void noSubstituteExceptionDefindedHandledBySuppress()
                                                    throws java.io.IOException
Specified by:
noSubstituteExceptionDefindedHandledBySuppress in interface MethodAnnotatedFoo
Throws:
java.io.IOException

throwsExceptionOnlyOnFirstCall

public void throwsExceptionOnlyOnFirstCall()
                                    throws java.io.IOException
Specified by:
throwsExceptionOnlyOnFirstCall in interface MethodAnnotatedFoo
Throws:
java.io.IOException

throwsExceptionEachTimeItIsCalled

public void throwsExceptionEachTimeItIsCalled()
                                       throws java.io.IOException
Specified by:
throwsExceptionEachTimeItIsCalled in interface MethodAnnotatedFoo
Throws:
java.io.IOException

throwsExceptionEachTimeItIsCalledWeExcpectRetriesWithDelay

public void throwsExceptionEachTimeItIsCalledWeExcpectRetriesWithDelay()
                                                                throws java.io.IOException
Specified by:
throwsExceptionEachTimeItIsCalledWeExcpectRetriesWithDelay in interface MethodAnnotatedFoo
Throws:
java.io.IOException


Copyright © 2007-2008. All Rights Reserved.