Thread:
 standardGeneratorScheme does not work 
 ipolevoy   06 Jan 2005, 14:47 
 Re: standardGeneratorScheme does not work 
 Geoff Clitheroe   11 Jan 2005, 02:51 
 Re: standardGeneratorScheme does not work 
 stefanm   22 Sep 2005, 08:42 
 Re: standardGeneratorScheme does not work 
 stefanm   22 Sep 2005, 11:32 

Comment
Prev. thread 
 Next thread
 
Prev. posting 
 Next posting
From: Geoff Clitheroe (11 Jan 2005, 02:51) Replies: 0, Views: 37341
Subject: Re: standardGeneratorScheme does not work
On 06 Jan 2005 14:47, ipolevoy wrote:

>I use middlegen 2.1.
>I need to change the generator class fron default
>"assigned" to another value, for instance "native".
>The Ant tag looks like this:

><hibernate standardGeneratorScheme="native" destination="${src.dir}"
>package="${target.package}"/>

>My output files are still generated with the "assigned" class
>regardless what value I provide in the build script:

><generator class="assigned" />

>Please, help!

I used Middlegen-Hibernate-r5 and the middlegen-hibernate-plugin-2.1.jar
from middlegen-2.1 and it works:

<hibernate
 destination="${build.gen-src.dir}"
 package="${name}.hibernate"
 standardGeneratorScheme="sequence"
 standardGeneratorArg="{0}_SEQ"
 genXDocletTags="false"
 javaTypeMapper="middlegen.plugins.hibernate.HibernateJavaTypeMapper"
/>

gives output like:

<generator class="sequence">
 <param name="sequence">MARK_SEQ</param>
</generator>
Prev. thread 
 Next thread
 
Prev. posting 
 Next posting
© Copyright 2006, Red Hat Middleware, LLC. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc. [Privacy Policy]