org.apache.commons.beanutils
Class PropsFirstPropertyUtilsBean

java.lang.Object
  extended by org.apache.commons.beanutils.PropertyUtilsBean
      extended by org.apache.commons.beanutils.PropsFirstPropertyUtilsBean

public class PropsFirstPropertyUtilsBean
extends PropertyUtilsBean

A PropertyUtilsBean which customises the behaviour of the setNestedProperty and getNestedProperty methods to look for simple properties in preference to map entries.


Constructor Summary
PropsFirstPropertyUtilsBean()
           
 
Method Summary
protected  Object getPropertyOfMapBean(Map bean, String propertyName)
          Note: this is a *very rough* override of this method.
protected  void setPropertyOfMapBean(Map bean, String propertyName, Object value)
          Note: this is a *very rough* override of this method.
 
Methods inherited from class org.apache.commons.beanutils.PropertyUtilsBean
clearDescriptors, copyProperties, describe, getIndexedProperty, getIndexedProperty, getInstance, getMappedProperty, getMappedProperty, getMappedPropertyDescriptors, getMappedPropertyDescriptors, getNestedProperty, getProperty, getPropertyDescriptor, getPropertyDescriptors, getPropertyDescriptors, getPropertyEditorClass, getPropertyType, getReadMethod, getResolver, getSimpleProperty, getWriteMethod, isReadable, isWriteable, setIndexedProperty, setIndexedProperty, setMappedProperty, setMappedProperty, setNestedProperty, setProperty, setResolver, setSimpleProperty
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PropsFirstPropertyUtilsBean

public PropsFirstPropertyUtilsBean()
Method Detail

getPropertyOfMapBean

protected Object getPropertyOfMapBean(Map bean,
                                      String propertyName)
                               throws IllegalAccessException,
                                      InvocationTargetException,
                                      NoSuchMethodException
Note: this is a *very rough* override of this method. In particular, it does not handle MAPPED_DELIM and INDEXED_DELIM chars in the propertyName, so propertyNames like "a(b)" or "a[3]" will not be correctly handled.

Overrides:
getPropertyOfMapBean in class PropertyUtilsBean
Throws:
IllegalAccessException
InvocationTargetException
NoSuchMethodException

setPropertyOfMapBean

protected void setPropertyOfMapBean(Map bean,
                                    String propertyName,
                                    Object value)
                             throws IllegalAccessException,
                                    InvocationTargetException,
                                    NoSuchMethodException
Note: this is a *very rough* override of this method. In particular, it does not handle MAPPED_DELIM and INDEXED_DELIM chars in the propertyName, so propertyNames like "a(b)" or "a[3]" will not be correctly handled.

Overrides:
setPropertyOfMapBean in class PropertyUtilsBean
Throws:
IllegalAccessException
InvocationTargetException
NoSuchMethodException


Copyright © 2000-2010 The Apache Software Foundation. All Rights Reserved.