Dennis Sosnoski wrote:

Sorry for the confusion with the RC2 release - I first had a broken download file, then managed to replace the home page of the JiBX site with that of the JibxSoap subproject. The difficulties of doing things from internet cafes, I suppose (I swear the Belgian beers had nothing to do with it...). Hopefully everything is fixed now.

Please let me know as soon as possible if you spot something wrong in either the documentation or the RC2 code. I plan to make this the production release next week unless something major turns up.


Here the thing I've spend most of the day beaing my head against the wall for. I've filed a bug in Jira for this, but it may not be a bug, just my misunderstanding of the new RC2 code.

I have a mapping (short version):

<mapping class="com.softstart.stellar.data.HexID" post-set="convertHextoID" abstract="true">
<value style="attribute" name="type" field="hexType" />
<value style="attribute" name="group" field="hexGroup" />
<value style="text" field="hex" />
</mapping>

I would like to use this mapping in two ways, as a structure in one mapping:

<mapping name="system" class="com.softstart.stellar.data.StarSystem" post-set="update">
<value style="attribute" name="id" field="key" />
<value style="attribute" name="provider" field="providerName" usage="optional" />
<value name="name" field="name" />
<structure field="location" name="location"/>
</mapping>

and as a collection of locations in another mapping:

<mapping name="link" class="com.softstart.stellar.data.Links">
<structure map-as="com.softstart.stellar.data.Record" />
<collection field="hexes" item-type="com.softstart.stellar.data.HexID"/>
<value style="attribute" name="linkType" field="linkTypeName" usage="optional"/>
</mapping>

In order for the second mapping to work (the links collection) I need to give the HexID mapping a name attribute. But if I do so the system mapping fails on reading, because it's now looking for a nested <location><location></location></location> tag. The unmarshal code throws a JiBX exception with the message "expected "location" start tag, found "location" end tag"

If I remove the name attribute from the (as above) I get another JiBX exception "no unmarshallar for element location".

How to address this issue?



--
        Thomas Jones-Low            Softstart Services Inc.
        [EMAIL PROTECTED]      JobScheduler for Oracle
        Ph: 802-398-1012            http://www.softstart.com


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click
_______________________________________________
jibx-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jibx-users

Reply via email to