public final class BeanPropertyUtils extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
BeanPropertyUtils.BeanPropertyUtilsImpl
Provided the implementation for the BeanUtils methods
|
| Constructor and Description |
|---|
BeanPropertyUtils() |
| Modifier and Type | Method and Description |
|---|---|
static Object |
convertPropertyValue(Object value,
Class<?> type)
Converts a bean property value to a specific Java type
|
static BeanPropertyUtils.BeanPropertyUtilsImpl |
getImplementation()
Returns the BeanUtils implementation
|
static Object |
getProperty(Object bean,
String property)
Returns the property of a bean by calling the correponding getter function
|
static int |
hasProperty(Object bean,
String property,
boolean writeAccess)
Checks if a bean has a particular property and a corresponding getter/setter method exists
|
static void |
setImplementation(BeanPropertyUtils.BeanPropertyUtilsImpl utils)
Allows to override the implementation
|
static boolean |
setProperty(Object bean,
String property,
Object value)
Set a single property value of a java bean object used by readProperties.
|
public static BeanPropertyUtils.BeanPropertyUtilsImpl getImplementation()
public static void setImplementation(BeanPropertyUtils.BeanPropertyUtilsImpl utils)
utils - the new BeanUtils implementationpublic static int hasProperty(Object bean, String property, boolean writeAccess)
bean - the bean to checkproperty - the property to checkwriteAccess - flag whether to check for the getter method (false) or the setter method (true)public static Object getProperty(Object bean, String property)
bean - the beanproperty - the property namepublic static boolean setProperty(Object bean, String property, Object value)
bean - the beanproperty - the propertyvalue - the valueCopyright © 2008–2023 Apache Software Foundation. All rights reserved.