org.easymock

Interface IAnswer<T>

public interface IAnswer<T>

Used to answer expected calls.

Method Summary

T
answer()
is called by EasyMock to answer an expected call.

Method Details

answer

public T answer()
            throws Throwable
is called by EasyMock to answer an expected call. The answer may be to return a value, or to throw an exception. The arguments of the call for which the answer is generated are available via EasyMock.getCurrentArguments() - be careful here, using the arguments is not refactoring-safe.
Returns:
the value to be returned