| Modifier and Type | Field and Description |
|---|---|
private java.lang.Throwable |
throwable |
| Constructor and Description |
|---|
ThrowAction(java.lang.Throwable throwable) |
| Modifier and Type | Method and Description |
|---|---|
private void |
checkTypeCompatiblity(java.lang.Class<?>[] allowedExceptionTypes) |
void |
describeTo(org.hamcrest.Description description) |
java.lang.Object |
invoke(Invocation invocation)
Performs an action in response to an invocation.
|
private boolean |
isThrowingCheckedException() |
private void |
reportIncompatibleCheckedException(java.lang.Class<?>[] allowedTypes) |
public java.lang.Object invoke(Invocation invocation) throws java.lang.Throwable
Invokableinvoke in interface Invokableinvocation - The invocation to perform.null if the invoked method has a void return type.java.lang.Throwable - An exception to be thrown to the caller, if not returning a value. Any checked exception
thrown must be in the throws list of the invoked method.public void describeTo(org.hamcrest.Description description)
describeTo in interface org.hamcrest.SelfDescribingprivate void checkTypeCompatiblity(java.lang.Class<?>[] allowedExceptionTypes)
private void reportIncompatibleCheckedException(java.lang.Class<?>[] allowedTypes)
private boolean isThrowingCheckedException()