[
http://opensource.atlassian.com/projects/hibernate/browse/ANN-480?page=co...
]
Diego Pires Plentz commented on ANN-480:
----------------------------------------
I'm concerned about the verbosity.
Agree.
Query by Example in annotation form
-----------------------------------
Key: ANN-480
URL:
http://opensource.atlassian.com/projects/hibernate/browse/ANN-480
Project: Hibernate Annotations
Issue Type: New Feature
Environment: jdk >= 1.5, hibernate >= 3, ant > 1.5
Reporter: M N G
Priority: Minor
Attachments: searchable.tar.gz
Interested in adsorbing this framework I built?
Takes all the work out of creating a Criteria. Similar to how Query by Example, this
small framework I wrote builds Criteria from annotated pojos.
A pojo is annotated to map hibernate bean mappings to methods. The annotated pojo's
class is registered in the Registry, which uses reflecting to define the signatures to
create the Criteria for the pojo. The values to search for are set in the pojo and the
pojo is passed to the Builder. The Builder uses the registry to create the Criteria
delimited by the values in the annotated pojo.
Not entirely mature yet (does not support all Criteria Restrictions) and the handling of
sorting results is a bit unwieldy. It works tho.
Attached is a copy of the framework. It includes a unit test that kick starts a HSQL
database to demostrate the framework.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira