Hibernate version: 3.1
I think there is a lot of confusion about how PropertySelectors work and what Example.excludeZeroes() does. The cause for this confusion comes from the lack of documentation in these two areas.
Documentation needs to be added to the following areas:
1. The Javadoc for the Example class needs to be modified to explain that only one PropertySelector can be set at a time, and list which methods set the Example's PropertySelector (ie: excludeNone, excludeZeroes, setPropertySelector). It should also be noted that enableLike, and ignoreCase do not override one another, and can be used in combination with one of the PropertySelector setters.
2. The Javadoc for Example.excludeZeroes() either needs to be modified to explain that this PropertySelector excludes properties with the null or Number(0) value, and does not exclude empty Strings (String("")).
Obviously a lot of users are looking for a way to exclude properties with empty Strings, so you may want to consider adding this logic to Example.excludeZeroes or creating an alternative called Example.excludeBlanks.
3. And finally, please cover Example.PropertySelector in the hibernate_reference.pdf, including the methods provided by Example. The QBE feature of the Hibernate framework is essential to simplifying the process of querying for Objects, the documentation is essential to the efficient implementation of the framework, and both of these factors increase Hibernate's value to customers like me.
Could someone from the Hibernate team please respond to this thread with whether or not these suggestions will be added to Hibernate in the future, and if so, when we might expect them?
Thank you for your time and effort.
|