Package org.mockito.invocation
Interface MockHandler
-
- All Superinterfaces:
java.io.Serializable
- All Known Subinterfaces:
InternalMockHandler<T>
public interface MockHandler extends java.io.Serializable
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.Object
handle(Invocation invocation)
Takes an invocation object and handles it.
-
-
-
Method Detail
-
handle
java.lang.Object handle(Invocation invocation) throws java.lang.Throwable
Takes an invocation object and handles it.The default implementation provided by Mockito handles invocations by recording method calls on mocks for further verification, captures the stubbing information when mock is stubbed, returns the stubbed values for invocations that have been stubbed, and much more.
- Parameters:
invocation
- The invocation to handle- Returns:
- Result
- Throws:
java.lang.Throwable
- Throwable
-
-