public abstract class BulkAccessor extends Object implements Serializable
Modifier and Type | Field and Description |
---|---|
protected String[] |
getters |
protected String[] |
setters |
protected Class |
target |
protected Class[] |
types |
Modifier | Constructor and Description |
---|---|
protected |
BulkAccessor()
Protected access constructor so the generated class has access to it.
|
Modifier and Type | Method and Description |
---|---|
static BulkAccessor |
create(Class beanClass,
String[] getters,
String[] setters,
Class[] types)
Creates a new instance of
BulkAccessor . |
String[] |
getGetters()
Returns the setter names of properties.
|
Class[] |
getPropertyTypes()
Returns the types of properties.
|
Object[] |
getPropertyValues(Object bean)
Returns the values of properties of a given bean.
|
abstract void |
getPropertyValues(Object bean,
Object[] values)
Obtains the values of properties of a given bean.
|
String[] |
getSetters()
Returns the getter names of the properties.
|
abstract void |
setPropertyValues(Object bean,
Object[] values)
Sets properties of a given bean to specified values.
|
protected Class target
protected String[] getters
protected String[] setters
protected Class[] types
protected BulkAccessor()
public abstract void getPropertyValues(Object bean, Object[] values)
bean
- JavaBean.values
- the obtained values are stored in this array.public abstract void setPropertyValues(Object bean, Object[] values)
bean
- JavaBean.values
- the values assinged to properties.public Object[] getPropertyValues(Object bean)
bean
- JavaBean.public Class[] getPropertyTypes()
public String[] getGetters()
public String[] getSetters()
public static BulkAccessor create(Class beanClass, String[] getters, String[] setters, Class[] types)
BulkAccessor
.
The created instance provides methods for setting/getting
specified properties at once.beanClass
- the class of the JavaBeans accessed
through the created object.getters
- the names of setter methods for specified properties.setters
- the names of getter methods for specified properties.types
- the types of specified properties.Copyright © 2019 JBoss by Red Hat. All rights reserved.