public class Shadow extends Object
Constructor | Description |
---|---|
Shadow() |
Modifier and Type | Method | Description |
---|---|---|
static void |
directInitialize(Class<?> clazz) |
|
static <R,T> R |
directlyOn(Class<T> clazz,
String methodName,
ReflectionHelpers.ClassParameter... paramValues) |
|
static <R> R |
directlyOn(Object shadowedObject,
String clazzName,
String methodName,
ReflectionHelpers.ClassParameter... paramValues) |
|
static <T> T |
directlyOn(T shadowedObject,
Class<T> clazz) |
|
static <R,T> R |
directlyOn(T shadowedObject,
Class<T> clazz,
String methodName,
ReflectionHelpers.ClassParameter... paramValues) |
|
static String |
directMethodName(String className,
String methodName) |
|
static <T> T |
extract(Object instance) |
Retrieve corresponding Shadow of the object.
|
static <R> R |
invokeConstructor(Class<? extends R> clazz,
R instance,
ReflectionHelpers.ClassParameter... paramValues) |
|
static <T> T |
newInstance(Class<T> clazz,
Class[] parameterTypes,
Object[] params) |
|
static <T> T |
newInstanceOf(Class<T> clazz) |
|
static Object |
newInstanceOf(String className) |
public static <T> T extract(Object instance)
public static <T> T newInstanceOf(Class<T> clazz)
public static <T> T newInstance(Class<T> clazz, Class[] parameterTypes, Object[] params)
public static <T> T directlyOn(T shadowedObject, Class<T> clazz)
public static <R> R directlyOn(Object shadowedObject, String clazzName, String methodName, ReflectionHelpers.ClassParameter... paramValues)
public static <R,T> R directlyOn(T shadowedObject, Class<T> clazz, String methodName, ReflectionHelpers.ClassParameter... paramValues)
public static <R,T> R directlyOn(Class<T> clazz, String methodName, ReflectionHelpers.ClassParameter... paramValues)
public static <R> R invokeConstructor(Class<? extends R> clazz, R instance, ReflectionHelpers.ClassParameter... paramValues)
public static void directInitialize(Class<?> clazz)