Hi,
I use hbm2java to generate mapping objects from the mapping file.
I'd like to generate wrapper type instead of primitive type by default.
I can't manage to do this.
I run hbm2java from the ant class.
Here's my mapping file:
<class name="com.airfrance.comor.enterpriselayer.businessobject.Escale"
proxy="com.airfrance.comor.enterpriselayer.businessobject.Escale" table="TESTENV_ESCALE" mutable="true">
<id name="codeIata" type="string" column="codeIata" length="64" unsaved-value="null">
<generator class="uuid.hex"/>
</id>
<version column="version_number" name="version" />
<property name="nom" length="25" type="string" />
<property name="typeEsc" type="char" />
</class>
</hibernate-mapping>
Here's the result:
/** @author Hibernate CodeGenerator */
public class Escale implements Serializable {
/** identifier field */
private String codeIata;
/** nullable persistent field */
private String nom;
/** nullable persistent field */
private char typeEsc;
/** nullable persistent field */
private int version;
etc...
I would like to have:
/** @author Hibernate CodeGenerator */
public class Escale implements Serializable {
/** identifier field */
private String codeIata;
/** nullable persistent field */
private String nom;
/** nullable persistent field */
private Character typeEsc;
/** nullable persistent field */
private Integer version;
etc...
Is there a way to do it?
I didn't find anything on the forum, web that map correctly this problem.
Thanks by advance.
Eric
[b]Hibernate version: 2.1.6[/b]
[b]Hibernate-extensions: 2.1.2[/b]
|