This question is locked. New answers and comments are not allowed.
Hi.
I would love to see the following functionality in future versions:
Background:
I have a base abstract perstent class with identity and version fields (ID, Version), which is mapped to a table 'PersistentObject'. All my persistent classes derives from this class, which means they all put an entry into this table on creation.
This table will of cource then grow very large over time and i would like to use separate tables for separate classes, with their own version/id columns.
One way to achieve this is to declare the class fields protected and do the mapping in the descendant classes, but this means exposing direct write access to fields which should alwas be read-only to both users and developers, and this poses a high risk. It also requires mapping be set up for the same fields in every class, which is error prone and time consuming.
What I would like to do, is what I've seen with another ORM vendor, to map the fields in the base class, but specify on a class (field even) that fields mapped in this class should use the table mapped by it's descendants. Recursively of course, should the descendant also specify this behaviour.
Thanks
Pål
I would love to see the following functionality in future versions:
Background:
I have a base abstract perstent class with identity and version fields (ID, Version), which is mapped to a table 'PersistentObject'. All my persistent classes derives from this class, which means they all put an entry into this table on creation.
This table will of cource then grow very large over time and i would like to use separate tables for separate classes, with their own version/id columns.
One way to achieve this is to declare the class fields protected and do the mapping in the descendant classes, but this means exposing direct write access to fields which should alwas be read-only to both users and developers, and this poses a high risk. It also requires mapping be set up for the same fields in every class, which is error prone and time consuming.
What I would like to do, is what I've seen with another ORM vendor, to map the fields in the base class, but specify on a class (field even) that fields mapped in this class should use the table mapped by it's descendants. Recursively of course, should the descendant also specify this behaviour.
Thanks
Pål