public class BeanUtils extends Object
BeanUtils provides functions for altering the way commons BeanUtils works| Modifier and Type | Field and Description |
|---|---|
static String |
SET_PROPERTIES_METHOD |
| Constructor and Description |
|---|
BeanUtils() |
| Modifier and Type | Method and Description |
|---|---|
static Map<String,Object> |
describeBean(Object object)
Similar to
describe(Object) except that it will only populate bean properties where there is a valid getter and
setter method. |
static void |
populate(Object bean,
Map props)
This will overlay a map of properties on a bean.
|
static void |
populateWithoutFail(Object object,
Map props,
boolean logWarnings)
Exception safe version of BeanUtils.populate()
|
public static final String SET_PROPERTIES_METHOD
public static void populateWithoutFail(Object object, Map props, boolean logWarnings)
object - the object to set the properties onprops - the map of properties to setlogWarnings - whether exception warnings should be loggedpublic static void populate(Object bean, Map props) throws IllegalAccessException, InvocationTargetException
bean - the bean on which to set the propertiesprops - a Map of properties to set on the beanIllegalAccessExceptionInvocationTargetExceptionpublic static Map<String,Object> describeBean(Object object)
describe(Object) except that it will only populate bean properties where there is a valid getter and
setter method. Basically this method will describe a bean and honour its encapsulation.object - the object to describeCopyright © 2003–2017 MuleSoft, Inc.. All rights reserved.