I double-checked, and adding is automatic if you're using the default templates:
public void addToContentList(com.gvea.announcement.entity.Content obj) {
addToManyTarget("contentList", obj, true);
}
The "true" is for "boolean setReverse"
-Mike
On 8/31/05, Gili <cowwo..bs.darktech.org> wrote:
>
> Good to hear. Thank you :)
>
> Gili
>
> Mike Kienenberger wrote:
> > For deletes this is possible. Just set the delete rule on your
> > ObjRelationship to cascade in the model. It defaults to nullify, I
> > believe. (Deny is the other option).
> >
> > For adds, I think it's automatic so long as you provide a reverse
> > ObjRelationship.
> >
> > On 8/31/05, Gili <cowwo..bs.darktech.org> wrote:
> >
> >>Hi,
> >>
> >> In Hibernate you can define cascades such that if you have a
> >>parent/child relationship and you add a child into the parent, the
> >>child's parent link is updated as well (i.e. bidirectional
> >>relationship). As well, if a parent is removed, you can set cascade so
> >>all children are automatically removed as well.
> >>
> >> Can the same thing be done under Cayenne?
> >>
> >>Gili
> >>--
> >>http://www.desktopbeautifier.com/
> >>
> >
> >
>
> --
> http://www.desktopbeautifier.com/
>
This archive was generated by hypermail 2.0.0 : Wed Aug 31 2005 - 13:00:07 EDT