I have a mapping file that specifies an object which contains a vector of
another object. I'm having a lot of trouble getting it to unmarshal.
Marshalling works fine.
My object is a ContentComposite and it contains a Vector of ItemId's. I am
unclear whether I should be trying to implement a setItemIds() method, a
addItemId(ItemId) method, or both. In any case, I've implemented both,
although neither gets called by the marshaller. The ItemIds
_are_instanciated however.
Any help would be appreciated (samples to follow)...
---------Mapping file--------------
....
<class name="com.vignette.apps.portal.cma.beans.ContentComposite">
<field name="id" type="integer"> <bind-xml node="attribute"/>
</field>
<!-- other non-primitives -->
<field name="name" type="string"/>
<field name="title" type="string"/>
....
<field name="itemIds" type="ItemId" collection="vector"> <bind-xml
name="ItemId"/> </field>
</class>
<class name="ItemId">
<field name="id" type="integer"> <bind-xml name="Id"
node="attribute"/> </field>
</class>
....
-----REsulting XML------------
<?xml version="1.0"?>
<com.vignette.apps.portal.cma.beans.Content-composite id="23732">
<name>Composite</name>
<title>Test Article 1</title>
<ItemId Id="23734"/>
<ItemId Id="23736"/>
<ItemId Id="23738"/>
<ItemId Id="23740"/>
<ItemId Id="23744"/>
<ItemId Id="23742"/>
<ItemId Id="23746"/>
</com.vignette.apps.portal.cma.beans.Content-composite>
Andrew Coulson
Software Architect; VGM-AST, Vignette Corp.
ofc: 512 741-1368 [EMAIL PROTECTED]
"The path to enlightenment is /usr/bin/enlightenment"
"Vignette is the leading provider of integrated content applications used by
the most successful organizations to interact online with their customers,
employees, and partners."
-----------------------------------------------------------
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
unsubscribe castor-dev