Hello all,
I updated JiBX from 1.1.5 to 1.2.5 today, because I want to use it with Java 7.
Now, some tests are failing because a part of the binding is not working as
before anymore.
This is the responsible part of the binding:
<!-- Node: container.md-records.md-record -->
<!-- Field: metadataSets [List<MetadataSetVO>] -->
<collection name="md-record"
ns="http://www.escidoc.de/schemas/metadatarecords/0.5" field="metadataSets"
factory="de.mpg.escidoc.services.common.xmltransforming.JiBXHelper.metadataSetVOListFactory"
item-type="de.mpg.escidoc.services.common.valueobjects.MetadataSetVO"
usage="optional" ordered="false" allow-repeats="true">
<structure name="publication"
ns="http://purl.org/escidoc/metadata/profiles/0.1/publication"
type="de.mpg.escidoc.services.common.valueobjects.publication.MdsPublicationVO"
usage="optional" ordered="false"/>
<structure name="yearbook"
ns="http://purl.org/escidoc/metadata/profiles/0.1/yearbook"
type="de.mpg.escidoc.services.common.valueobjects.publication.MdsYearbookVO"
usage="optional" ordered="false"/>
<structure name="virr-book"
ns="http://www.loc.gov/mods/v3" usage="optional" flexible="true"
ordered="false"/>
<structure name="mab-md" usage="optional"
ordered="false" flexible="true"/>
<!-- Faces -->
<structure name="faces-album"
type="de.mpg.escidoc.services.common.valueobjects.face.MdsFacesContainerVO"
usage="optional" ordered="false"/>
<structure name="dc-md" usage="optional"
ordered="false" flexible="true"/>
</collection>
So there can occur a collection of md-record tags, which can have different
child elements. For several of those elements (publication, yearbook,
faces-album), there is a binding available. Some other elements (virr-book,
mab-md, dc-md) should be ignored together with their children (according to
http://jibx.sourceforge.net/tutorial/binding-structures.html#figure7). And this
is the critical point: The children of these elements are not ignored anymore.
If I want to marshall a xml with the following md-record:
<escidocMetadataRecords:md-record name="escidoc"
xmlns:escidocMetadataRecords="http://www.escidoc.de/schemas/metadatarecords/0.5">
<virr-book xmlns="http://www.loc.gov/mods/v3">
<mods version="3.2"/>
</virr-book>
</escidocMetadataRecords:md-record>
I get the following exception: org.jibx.runtime.JiBXException: Expected
"{http://www.loc.gov/mods/v3}virr-book" end tag, found
"{http://www.loc.gov/mods/v3}mods" start tag (line 35, col 25).
So the content of virr-book is not ignored anymore. But it worked with JiBX
1.1.5.
Any advice how to ignore element content with JiBX 1.2.5?
Thank you.
Best Regards
Markus
------------------------------------------------------------------------------
How ServiceNow helps IT people transform IT departments:
1. Consolidate legacy IT systems to a single system of record for IT
2. Standardize and globalize service processes across IT
3. Implement zero-touch automation to replace manual, redundant tasks
http://pubads.g.doubleclick.net/gampad/clk?id=51271111&iu=/4140/ostg.clktrk
_______________________________________________
jibx-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jibx-users