Hello Keith,
As indicated in the XML document given below:
Auftragposition references its parent Auftrag.....
The current version of the XML document generated is as follows:
<Auftragsposition AuftragspositionOID="1019738737353">
<betragBrutto>0.0</betragBrutto>
<betragOffen>0.0</betragOffen>
<Zahlungsart>B</Zahlungsart>
<TpGebiet>18</TpGebiet>
<AuftragErteiltDatum>2002-04-25T14:45:38.000</AuftragErteiltDatum>
<ErfasstVon>0100002371</ErfasstVon>
</MyAuftrag>
</Auftragsposition >
We just want an reference to the auftrag object with the primary key being the auftragOID...
and are expecting the resultant document to be some what like the foloowing...with a refernce to the auftrag with the auftragOID as an attribute...
<Auftragsposition AuftragspositionOID="1019738737353">
<betragBrutto>0.0</betragBrutto>
<betragOffen>0.0</betragOffen>
<Zahlungsart>B</Zahlungsart>
<TpGebiet>18</TpGebiet>
</Auftragsposition >
The mappinf wht i have used is:
Mappinf content:
<class name="com.dekra.automobil.auftragswesen.pbo.vbsf.PBOVBSFAuftrag" identity="auftragOID">
<map-to xml="Auftrag"/>
<field name="auftragOID" type="java.lang.String">
<bind-xml name="AuftragOID" node="attribute"/>
</field>
<map-to xml="Auftrag"/>
<field name="auftragOID" type="java.lang.String">
<bind-xml name="AuftragOID" node="attribute"/>
</field>
</class>
<class name="com.dekra.automobil.auftragswesen.pbo.vbsf.PBOVBSFAuftragsposition" identity="auftragspositionOID">
<map-to xml="Auftragsposition"/>
<map-to xml="Auftragsposition"/>
<field name="MyAuftrag" type="com.dekra.automobil.auftragswesen.pbo.vbsf.PBOVBSFAuftrag" get-method="getMyAuftrag">
<bind-xml name="MyAuftrag" node="element" reference="true"/>
</field>
<bind-xml name="MyAuftrag" node="element" reference="true"/>
</field>
</class>
We are using the castor tool only for the marshalling and the unmarshalling of the java object model using the mapping file.
I am using the CVS version :
castor 0.9.3-jar file..
The mapping.dtd indicates the reference and the identity tags...
Kindly let me know the correct way of representing the same.....
Does castor not support references???????
I have laready posted the same query couple of times, i am yet to have a answer for the same.
Your prompt response would highly be appreciated.
Regards,
Chetan Rathi
Augsburger Str.336
70327 Stuttgart
Tel no.0711-7861-3148(off.)
Handy.no.015055564671
Get your FREE download of MSN Explorer at http://explorer.msn.com.
----------------------------------------------------------- If you wish to unsubscribe from this mailing, send mail to [EMAIL PROTECTED] with a subject of: unsubscribe castor-dev
