Re: One to many relationships require reverse relationships?

From: Andrus Adamchik (andru..bjectstyle.org)
Date: Thu Apr 24 2003 - 13:41:41 EDT

  • Next message: Andrus Adamchik: "Re: can't run cayenne-web-app 1.0b1"

    Hi Scott,

    > I saw the many-to-many relationship example in the users guide but am
    > wondering why I have to create reverse relationships even when I build a
    > one-to-many relationship?

    Cayenne always requires a reverse *Db* relationship, but not *Obj*
    relationship. So from the object model perspective you are OK: your Java
    classes will only have the required methods, and no artificial "reverse"
    properties are needed.

    This is just the way inner working is done in Cayenne. In the future we
    will most likely implement DbRelationships to be bidirectional by
    definition to avoid such confusion.

    >
    > Don't get me wrong, Cayenne does have one of the better user guides I've
    > seen for open source software, especially after reading some Castor and
    > Jakarta OJB docs... (or what exists.)

    Thanks for the compliment. Doing our best :-)

    Andrus



    This archive was generated by hypermail 2.0.0 : Thu Apr 24 2003 - 13:41:43 EDT