[xsd-users] Issue with maintaining order

Babinskas, Albert albert.babinskas at imagingsciences.com
Thu Feb 19 10:34:27 EST 2015


HI Boris,
I am investigating solution provided in manual section "2.8.4 Element Order". 

But my XSD type is not labeled MIXED. The only way I could get annotationList::order_type, and get ellipse_id is when I would use compile option --ordered-type-all. 
But that creates issues for the rest of the project. 

I tried --ordered-type annotationList --ordered-type-derived, but that didn't provide me the functionality I needed. What am I doing wrong?

-Albert


-----Original Message-----
From: Boris Kolpackov [mailto:boris at codesynthesis.com] 
Sent: Thursday, February 19, 2015 9:18 AM
To: Babinskas, Albert
Cc: 'xsd-users at codesynthesis.com'
Subject: Re: [xsd-users] Issue with maintaining order

Hi Albert,

Babinskas, Albert <albert.babinskas at imagingsciences.com> writes:

> But the order is not preserved.

In 4.0.0 we've added a feature specifically for that. Check Section 2.8.4, "Element Order" in the C++/Tree Mapping User Manual:

http://codesynthesis.com/projects/xsd/documentation/cxx/tree/manual/#2.8.4


> Is there a way after XML is parsed into XSD objects, to access DOM 
> structure of that Object? For example if I would be able to access 
> annotationList Document, or have an iterator over the annotationList.

Yes, you can use the DOM association feature. But the above approach is easier to use and it works for both parsing and serialization while the DOM association will only work for parsing.

Boris



More information about the xsd-users mailing list