public class MapAccessor extends Object implements PropertyAccessor
PropertyAccessor for getting and setting Map values.| Constructor and Description |
|---|
MapAccessor(String key)
Constructs a new MapAccessor.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getConstructorArgumentIndex()
Returns the constructor argument index, or -1 if this property is
not a constructor argument.
|
Object |
getValue(Object bean)
Returns the property value from a bean object.
|
boolean |
isConstructorArgument()
Returns whether this property is a constructor argument.
|
void |
setValue(Object bean,
Object value)
Sets the property value on a bean object.
|
public MapAccessor(String key)
key - the key used to get and set a value from a Map beanpublic Object getValue(Object bean)
PropertyAccessorgetValue in interface PropertyAccessorbean - the bean object to get the property frompublic void setValue(Object bean, Object value)
PropertyAccessorsetValue in interface PropertyAccessorbean - the bean object to set the propertyvalue - the property valuepublic boolean isConstructorArgument()
PropertyAccessorisConstructorArgument in interface PropertyAccessorpublic int getConstructorArgumentIndex()
PropertyAccessorgetConstructorArgumentIndex in interface PropertyAccessor