.. java:import:: org.apache.commons.beanutils MethodUtils .. java:import:: org.apache.commons.beanutils PropertyUtils .. java:import:: org.apache.commons.lang StringUtils .. java:import:: org.slf4j Logger .. java:import:: org.slf4j LoggerFactory .. java:import:: java.beans IntrospectionException .. java:import:: java.beans PropertyDescriptor .. java:import:: java.lang.reflect InvocationTargetException .. java:import:: java.lang.reflect Method PropertyUtil ============ .. java:package:: org.motechproject.mds.util :noindex: .. java:type:: public final class PropertyUtil extends PropertyUtils The \ ``PropertyUtil``\ util class provides the same method like \ :java:ref:`org.apache.commons.beanutils.PropertyUtils`\ and two additional methods for safe writing and reading property in the given bean. Methods ------- getPropertyDescriptors ^^^^^^^^^^^^^^^^^^^^^^ .. java:method:: public static PropertyDescriptor[] getPropertyDescriptors(Object bean) :outertype: PropertyUtil safeGetProperty ^^^^^^^^^^^^^^^ .. java:method:: public static Object safeGetProperty(Object bean, String name) :outertype: PropertyUtil safeSetProperty ^^^^^^^^^^^^^^^ .. java:method:: public static void safeSetProperty(Object bean, String name, Object value) :outertype: PropertyUtil