mysema/querydsl — Issue #42: Mapping for sqlinsertclause based upon annotations
Author: manfreddev
Created: 2011-11-08 18:52:23+00:00
State: open

Currenty, the populate method of the sqlinsertclause makes mappings based upon bean property names.
If there would be a possibility to do the mapping based upon property annotations, then the bean property names and the physical table field names don't need to match. This gives extra flexibility.

A suggested system would be to have some kind of "Mapper" system that lets you map between bean properties and the physical fields with custom mapping if required, and one implementation that is based upon annotations

SQLInsertClause.populate(Object aBean, BeanMapper aBeanMapper)

Where you have ...

PropertyBasedBeanMapper
AnnotationBasedBeanMapper
MyCustomCodedBeanMapper

This would give most flexibility.

https://groups.google.com/forum/#!topic/querydsl/UNU34YPsmZw