org.jboss.seam.util
public class Reflections extends Object
Constructor and Description |
---|
Reflections() |
Modifier and Type | Method and Description |
---|---|
static Class |
classForName(String name) |
static Object |
get(Field field,
Object target) |
static Object |
getAndWrap(Field field,
Object target) |
static Class |
getCollectionElementType(Type collectionType) |
static Field |
getField(Class clazz,
String name) |
static List<Field> |
getFields(Class clazz,
Class annotation)
Get all the fields which are annotated with the given annotation.
|
static Method |
getGetterMethod(Class clazz,
String name) |
static List<Method> |
getGetterMethods(Class clazz,
Class annotation)
Get all the getter methods annotated with the given annotation.
|
static Class |
getMapKeyType(Type collectionType) |
static Method |
getMethod(Annotation annotation,
String name) |
static Method |
getMethod(Class clazz,
String name) |
static Method |
getSetterMethod(Class clazz,
String name) |
static Object |
invoke(Method method,
Object target,
Object... args) |
static Object |
invokeAndWrap(Method method,
Object target,
Object... args) |
static boolean |
isClassAvailable(String name)
Return's true if the class can be loaded using Reflections.classForName()
|
static boolean |
isInstanceOf(Class clazz,
String name)
Check to see if clazz is an instance of name
|
static void |
set(Field field,
Object target,
Object value) |
static void |
setAndWrap(Field field,
Object target,
Object value) |
static String |
toString(Member member) |
static String |
toString(Method method) |
public static Object invoke(Method method, Object target, Object... args) throws Exception
Exception
public static void set(Field field, Object target, Object value) throws Exception
Exception
public static Class classForName(String name) throws ClassNotFoundException
ClassNotFoundException
public static boolean isClassAvailable(String name)
public static List<Method> getGetterMethods(Class clazz, Class annotation)
public static List<Field> getFields(Class clazz, Class annotation)
public static Method getMethod(Annotation annotation, String name)
Copyright © 2015 Seam Framework. All Rights Reserved.