db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thomas Dudziak <to...@first.fhg.de>
Subject Re: Proposal to get rid of ojbConcreteClass
Date Sat, 07 Aug 2004 15:17:31 GMT
Jakob Braeuchi wrote:

> the jdo approach may be even better because it does not reference an 
> ordinary field. so we could also move the relevant jdbc-information into 
> the selector:
> <class-descriptor
>     class="org.apache.ojb.broker.ObjectRepository$A"
>     table="AB_TABLE"
>  >
>     <selector-descriptor
>          column="class_mame"
>          jdbc-type="STRING"
>          value="class_a"
>     />
>     <field-descriptor
>          name="id"
>          column="ID"
>          jdbc-type="INTEGER"
>          primarykey="true"
>          autoincrement="true"
>     />
>     ...
>  </class-descriptor>

JDO has a special descriptor that defines the inheritance strategy:

<inheritance strategy="superclass-table">
    <discriminator strategy="class-name" column="JAVA_CLS"/>

The strategy is either new-table (one table per class), superclass-table 
(mapped to the same table as the - in respect to persistence - direct 
superclass), and no-table (fields of this subclass are in a separate 
table, i.e. our multiple-joined tables strategy). Depending on the 
strategy, the discriminator specifies the connection point(s).

Perhaps it would be useful to adapt this pattern (and the some of the 
names), e.g. deprecate the super-reference and put it in such a special 
descriptor ?


To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-dev-help@db.apache.org

View raw message