[xsd-users] Hierarchies and code generation.

Boris Kolpackov boris at codesynthesis.com
Wed Mar 2 08:55:19 EST 2011


Hi Joël,

Klaim - Joël Lamotte <mjklaim at gmail.com> writes:

> I'm not sure I understand it fully though, because of the use of elements
> outside of complexType definition (I have only the root element in my xsd)
>
> Why is an element required for the base (root) type?
> Should I do this for my abstract element types?

That's how the substitution groups mechanism works in XML Schema.

For XSD-specific details on this feature, see Section 2.11, "Mapping for
xsi:type and Substitution Groups" in the C++/Tree Mapping User Manual:

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

Boris



More information about the xsd-users mailing list