cayenne-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael Gentry" <blackn...@gmail.com>
Subject Re: help on saving obj using relations
Date Thu, 17 Apr 2008 15:46:54 GMT
I looked at:

http://oswing.svn.sourceforge.net/viewvc/oswing/trunk/srcdemo/demo36/auto/_EmpVO.java?revision=214&view=markup

And I don't believe you have modeled your relationships correctly.
You manually created a get/setDept() and get/setTask() in the
subclass:

http://oswing.svn.sourceforge.net/viewvc/oswing/trunk/srcdemo/demo36/EmpVO.java?revision=214&view=markup

However, those should be generated by Cayenne in the parent
(_EmpVO.java) class.  At least if you have your relationships modeled
correctly.  Go back into the modeler and look under the Relationship
tab for both your DbEntity and your ObjEntity and make sure they are
defined in each place.  You may need to synchronize your ObjEntity
with your DbEntity (click the sync button).  After you get your
relationships defined, regenerate your superclasses.

/dev/mrg



On Thu, Apr 17, 2008 at 11:03 AM, Gustav Weber <gustav_weber75@yahoo.com> wrote:
> I guess Mauro forgot to mention an important aspect:
>
>  The situation appeared while integrating Cayenne with
>  OpenSwing:
>  http://oswing.sourceforge.net/
>
>  and the problem he describes can be seen/reproduced
>  from the code example in "srcdemo/demo36" from the
>  project's Sourceforge SVN repository:
>  http://sourceforge.net/projects/oswing/
>
>  regards,
>  Gustav.
>
>
>
>       ____________________________________________________________________________________
>  Be a better friend, newshound, and
>  know-it-all with Yahoo! Mobile.  Try it now.  http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
>
>

Mime
View raw message