org.xwiki.component.util
Class ReflectionUtils
java.lang.Object
org.xwiki.component.util.ReflectionUtils
public class ReflectionUtils
- extends Object
Various Reflection utilities.
- Since:
- 2.1RC1
- Version:
- $Id$
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ReflectionUtils
public ReflectionUtils()
getAllFields
public static Collection<Field> getAllFields(Class<?> componentClass)
- Parameters:
componentClass - the class for which to return all fields
- Returns:
- all fields declared by the passed class and its superclasses
setFieldValue
public static void setFieldValue(Object instanceContainingField,
String fieldName,
Object fieldValue)
- Sets a value to a field using reflection even if the field is private.
Copyright © 2004-2011 XWiki. All Rights Reserved.