cayenne-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrus Adamchik <and...@objectstyle.org>
Subject Re: cgen bug - unexpanded template variables
Date Wed, 24 Aug 2011 20:42:32 GMT
One final try - if you generate the classes from the Modeler "Tools > Generate Classes"
is it resulting in the same problem?

On Aug 24, 2011, at 6:47 PM, Joel Becker wrote:

> (I had to re-subscribe with a different e-mail because of filtering)
> 
> I'm using Cayanne Modeller 3.0.2 and the 3.0.2 maven plug-ings.
> 
> I did have some warnings in the schema (some tables lacked a pk), but
> after fixing them, saving, and re-generating, I get the same errors.
> 
> 
> I am sure I've seen it before. IIRC certain errors in the DataMap caused
> similar behavior for
> me. So which version of Cayenne is this and also are there any warnings when
> you save your
> project in the Modeler?
> (If we can't come with an answer based on this info, I guess you may open a
> Jira and attach
> the problematic DataMap to it so that somebody could debug it, and at least
> improve the Modeler
> validation - https://issues.apache.org/jira/browse/CAY ).
> Cheers,
> Andrus
> On Aug 24, 2011, at 5:11 PM, Becker, Joel wrote:
>> Hello everyone. I reverse-engineered an existing database in Cayenne
>> modeler -worked very smoothly-then I created a maven project and ran the
>> cgen plugin on the resulting mapping files (there are 2, one for each of
>> 2 data nodes / schemas). The first worked fine. For the second, in the
>> generated java POJOs, about half or more of the addTo*Array() and
>> removeFrom*Array() methods have for a parameter
>> "$importUtils.formatJavaType(${rel.TargetEntity.ClassName}) obj", which
>> obviously results in compiler errors. This looks like an unexpanded
>> variable from the code templates, like maybe it's not being set? Is this
>> a known bug? Is there a work-around?
>> 
>> 
>> 
>> Thanks!
>> 
>> Joel
>> 
>> 
>> 


Mime
View raw message