org.activiti.engine.impl.util
类 ReflectUtil

java.lang.Object
  继承者 org.activiti.engine.impl.util.ReflectUtil

public abstract class ReflectUtil
extends Object

作者:
Tom Baeyens

构造方法摘要
ReflectUtil()
           
 
方法摘要
static ClassLoader getClassLoader()
           
static Field getField(String fieldName, Class<?> clazz)
          Returns the field of the given class or null if it doesnt exist.
static Field getField(String fieldName, Object object)
          Returns the field of the given object or null if it doesnt exist.
static URL getResource(String name)
           
static InputStream getResourceAsStream(String name)
           
static Method getSetter(String fieldName, Class<?> clazz, Class<?> fieldType)
          Returns the setter-method for the given field name or null if no setter exists.
static Object instantiate(String className)
           
static Object instantiate(String className, Object[] args)
           
static Object invoke(Object target, String methodName, Object[] args)
           
static Class<?> loadClass(String className)
           
static void setField(Field field, Object object, Object value)
           
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

构造方法详细信息

ReflectUtil

public ReflectUtil()
方法详细信息

getClassLoader

public static ClassLoader getClassLoader()

loadClass

public static Class<?> loadClass(String className)

getResourceAsStream

public static InputStream getResourceAsStream(String name)

getResource

public static URL getResource(String name)

instantiate

public static Object instantiate(String className)

invoke

public static Object invoke(Object target,
                            String methodName,
                            Object[] args)

getField

public static Field getField(String fieldName,
                             Object object)
Returns the field of the given object or null if it doesnt exist.


getField

public static Field getField(String fieldName,
                             Class<?> clazz)
Returns the field of the given class or null if it doesnt exist.


setField

public static void setField(Field field,
                            Object object,
                            Object value)

getSetter

public static Method getSetter(String fieldName,
                               Class<?> clazz,
                               Class<?> fieldType)
Returns the setter-method for the given field name or null if no setter exists.


instantiate

public static Object instantiate(String className,
                                 Object[] args)


Copyright © 2013 Alfresco. All rights reserved.