commons-beanutils

How to ask BeanUtils to ignore null values

Using Commons beanUtils I would like to know how to ask any converter say the Dateconverter to ignore null values and use null as default. As an example consider a public class, public class X { private Date date1; private String string1; //add public getters and setters } and my convertertest as, public class Apache { ...

How to prevent NPE when accessing a nested/indexed property of a bean

Is there any way to prevent NPE when accessing a nested bean using commons-beanutils? Here is my code: new BeanUtilsBean().getProperty(human, "parent.name"); In this case I want getProperty() to either return empty string ("") when human.getParent() == null or handle it in a way other that throwing an NPE. ...

Beans, Lists and JSP

Hi at All I have a little question... On my JSP page I have a List of beans. I want to extract a sublist of beans with a specific property (Ex. all Horror books). Can Apache Beanutils help me? Thanks in advance... ...

commons beanutils alternative

Hi all, I am looking for a commons beanutils alternative. The reason is that beanutils relies on commons-logging which is conflicting with existing libraries I am using. I would like a small self-contained alternative which will cause no/minimal conflicts. The main functionality I am after is nested property retrieval. Thanks in advan...