[xsd-users] Elements of same time in different heirarchy

Boris Kolpackov boris at codesynthesis.com
Fri Mar 7 01:29:42 EST 2008


Hi Shiva,

Balasubramanyam, Shivakumar <sbalasub at qualcomm.com> writes:

> I noticed that an element X cannot be repeated even if it is present in
> a different hierarchy.
>
>
> When I compile each as FileOne.o and FileTwo.o and finally link to a
> single executable, I would get multiple declaration error.

I would need to see a real schema to say for sure what's going on
here. Generally, if two schemas with the same namespace (or with
different schema namespaces which are mapped to the same C++
namespace) have any global type definitions or element declarations,
then you will get conflicting symbols. This is, however, pretty easy
to resolve: just put the generated code for one of the schemas into
a different C++ namespace (--namespace-map option).

Boris




More information about the xsd-users mailing list