public static Object getNullSaveProperty(final Object pbean, final String pname)
      throws IllegalAccessException, InvocationTargetException, NoSuchMethodException {
    Object property;
    try {
      property = PropertyUtils.getProperty(pbean, pname);
    } catch (final NestedNullException pexception) {
      property = null;
    }
    return property;
  }
public static Object getNullSaveProperty ( final Object pbean , final String pname ) throws IllegalAccessException , InvocationTargetException , NoSuchMethodException { Object property ; try { property = PropertyUtils . getProperty ( pbean , pname ) ; } catch ( final NestedNullException pexception ) { property = null ; } return property ; }
<p>
Return the value of the specified property of the specified bean, no matter which property
reference format is used, as a String.
</p>
<p>
If there is a null value in path hierarchy, exception is cached and null returned.
</p>

@param pbean Bean whose property is to be extracted
@param pname Possibly indexed and/or nested name of the property to be extracted
@return The property's value, converted to a String

@exception IllegalAccessException if the caller does not have access to the property accessor
method
@exception InvocationTargetException if the property accessor method throws an exception
@exception NoSuchMethodException if an accessor method for this property cannot be found
@see BeanUtilsBean#getProperty