You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-users@xerces.apache.org by Go...@trilogy.com on 2005/02/07 06:42:29 UTC
includes in imported xsd
I have XML schemas that are structured as follows:
Namespace1: (all have the targetNamespace set to Namespace1)
A.xsd
Namespace2: (all have the targetNamespace set to Namespace2)
B.xsd
C.xsd
D.xsd
The A.xsd "import"s B.xsd with namespace "Namespace2". B.xsd in turn
"include"s C.xsd, which in turn "include"s D.xsd.
I am using xerces2 java parser, with schema validation turned on and for
some reason, it looks like, it
evaluates the "import"ed xsd but not the "include"d ones!! I end up with
an exception:
Cannot resolve the name 'ddd' to a(n) element declaration component. (where ddd is defined in D.xsd).
Some messages on mailing lists suggest to use a "wrapper" xsd, which
"include"s all the sub-xsd's you want,
and "import" that. Tried this, but get the same exception except that its
now on the bbb element (which is defined in B.xsd).
This is a problem with evaluation of "include"s since it works fine if I
just copy the content of C.xsd and D.xsd into B.xsd instead of
"include"ing.
Anyone faced similar situation before? Is this a problem or what may I be
doing wrong?? Help!!
--gowri
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-user-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-user-help@xml.apache.org