Re: flattened relations on_the_fly

From: Andrus Adamchik (andru..bjectstyle.org)
Date: Fri Jul 15 2005 - 03:57:54 EDT

  • Next message: Jürgen Saar: "Re: flattened relations on_the_fly"

    You can easily change anything in the mapping during runtime using
    Cayenne API (org.objectstyle.cayenne.map package). You can get access
    to DataMap and Entity objects via EntityResolver. Two things to watch
    for:

    1. Mapping is shared by all DataContexts within DataDomain, so a
    change will be visible to all sessions.

    2. Class API - if your change affects ObjRelationships as well as
    DbRelationships (e.g. if you add a new relationship instead of
    substituting an existing one), DataObjects will continue to work, as
    Cayenne doesn't use introspection. However your class won't have
    accessors for this new property, so you'd have to use "readProperty"
    to get access such relationship.

    Andrus

    On Jul 15, 2005, at 10:14 AM, Jürgen Saar wrote:
    > Hi,
    >
    > in my actual project it would help a lot, to build
    > a flattened relation in a customer specific way.
    >
    > So I would like to find a way to access a
    > flattened relationship that is not in the xxx.map.xml
    > but comes from a customer specific property-file
    >
    > Is there a way?
    >
    > Thanx
    > --- Juergen ---



    This archive was generated by hypermail 2.0.0 : Fri Jul 15 2005 - 03:57:56 EDT