@API(status=EXPERIMENTAL,
since="1.7.4")
public interface MethodLifecycleContext
extends LifecycleContext
PropertyLifecycleContext,
TryLifecycleContext| Modifier and Type | Method and Description |
|---|---|
java.lang.Class<?> |
containerClass()
The container class in which the current property method is running.
|
java.lang.reflect.Method |
targetMethod()
The method that defines the current property or example.
|
java.lang.Object |
testInstance()
The current instance of the property's container class.
|
java.util.List<java.lang.Object> |
testInstances()
The list of the current instance of the property's container class and all its outer objects
if it is in a nested class.
|
findAnnotation, findAnnotationsInContainer, findRepeatableAnnotations, label, newInstance, optionalContainerClass, optionalElement, reporter, resolveParameter, wrapReporter@API(status=MAINTAINED,
since="1.4.0")
java.lang.reflect.Method targetMethod()
@API(status=MAINTAINED,
since="1.4.0")
java.lang.Class<?> containerClass()
Most of the time that's also the defining class. It differs when running properties that are defined in a super class or an implemented interface.
@API(status=MAINTAINED,
since="1.4.0")
java.lang.Object testInstance()
@API(status=MAINTAINED,
since="1.5.4")
java.util.List<java.lang.Object> testInstances()