public final class ReflectionUtil extends Object
Modifier and Type | Class and Description |
---|---|
static class |
ReflectionUtil.ConstructorFactory |
static interface |
ReflectionUtil.Factory |
static class |
ReflectionUtil.StaticFactory |
Modifier and Type | Method and Description |
---|---|
static List<Field> |
findAllFieldsByType(Class typeClass,
Object propertyValue,
Set<Option> options) |
static List<Method> |
findAllSetters(Class typeClass,
String propertyName,
Object propertyValue,
Set<Option> options)
Finds all valid setters for the property.
|
static List<Method> |
findAllSettersByType(Class typeClass,
Object propertyValue,
Set<Option> options) |
static ReflectionUtil.ConstructorFactory |
findConstructor(Class typeClass,
List<? extends Class<?>> parameterTypes,
Set<Option> options) |
static ReflectionUtil.ConstructorFactory |
findConstructor(Class typeClass,
List<String> parameterNames,
List<? extends Class<?>> parameterTypes,
Set<String> availableProperties,
Set<Option> options) |
static Field |
findField(Class typeClass,
String propertyName,
Object propertyValue,
Set<Option> options) |
static Method |
findGetter(Class typeClass,
String propertyName,
Set<Option> options) |
static Method |
findInstanceFactory(Class typeClass,
String factoryMethod,
Set<Option> options) |
static Method |
findSetter(Class typeClass,
String propertyName,
Object propertyValue,
Set<Option> options) |
static ReflectionUtil.StaticFactory |
findStaticFactory(Class typeClass,
String factoryMethod,
List<? extends Class<?>> parameterTypes,
Set<Option> options) |
static ReflectionUtil.StaticFactory |
findStaticFactory(Class typeClass,
String factoryMethod,
List<String> parameterNames,
List<? extends Class<?>> parameterTypes,
Set<String> allProperties,
Set<Option> options) |
static List<String> |
getParameterNames(Constructor<?> constructor) |
static List<String> |
getParameterNames(Method method) |
public static Field findField(Class typeClass, String propertyName, Object propertyValue, Set<Option> options)
public static Method findGetter(Class typeClass, String propertyName, Set<Option> options)
public static Method findSetter(Class typeClass, String propertyName, Object propertyValue, Set<Option> options)
public static List<Method> findAllSetters(Class typeClass, String propertyName, Object propertyValue, Set<Option> options)
typeClass
- the class to search for setterspropertyName
- the name of the propertypropertyValue
- the value that must be settable either directly or after conversionoptions
- controls which setters are considered validpublic static List<Field> findAllFieldsByType(Class typeClass, Object propertyValue, Set<Option> options)
public static List<Method> findAllSettersByType(Class typeClass, Object propertyValue, Set<Option> options)
public static ReflectionUtil.ConstructorFactory findConstructor(Class typeClass, List<? extends Class<?>> parameterTypes, Set<Option> options)
public static ReflectionUtil.ConstructorFactory findConstructor(Class typeClass, List<String> parameterNames, List<? extends Class<?>> parameterTypes, Set<String> availableProperties, Set<Option> options)
public static ReflectionUtil.StaticFactory findStaticFactory(Class typeClass, String factoryMethod, List<? extends Class<?>> parameterTypes, Set<Option> options)
public static ReflectionUtil.StaticFactory findStaticFactory(Class typeClass, String factoryMethod, List<String> parameterNames, List<? extends Class<?>> parameterTypes, Set<String> allProperties, Set<Option> options)
public static Method findInstanceFactory(Class typeClass, String factoryMethod, Set<Option> options)
public static List<String> getParameterNames(Constructor<?> constructor)
Copyright © 2005-2012. All Rights Reserved.