W3C home > Mailing lists > Public > www-xml-schema-comments@w3.org > January to March 2001

problem with the structures DTD

From: Gignac Donald A CRBE <GignacDA@nswccd.navy.mil>
Date: Tue, 20 Mar 2001 13:42:22 -0500
Message-ID: <1F9F67162ADED3119F18009027A8F404C603B3@crbeex03.dt.navy.mil>
To: "'www-xml-schema-comments@w3.org'" <www-xml-schema-comments@w3.org>
Cc: "Westbrook Evelyn L (Lori) CRBE" <WestbrookEL@nswccd.navy.mil>, Junod L J II CRBE <JunodLJ@nswccd.navy.mil>
1.  The "XML Schema schema for XML Schemas: Part 2: Datatypes" does not parse against the schema DTD with the identifier "-//W3C//DTD XMLSCHEMA 200102//EN". This is because that the 's' parameter entity

	<!ENTITY % s ''>

defined in the external subset results in the "xmlns" attribute being defined twice for the "schema" element type. This is due to fact that the

	<!ENTITY % s ''>

defined in the external subset takes precedence over the 

	<!ENTITY % s ':xs'>

defined in the internal subset. This results in the replacement text of the "nds" parameter entity 

	<!ENTITY % nds 'xmlns%s;'>

being defined as 'xmlns'. This causes the 'xmlns' attribute to be defined twice for the 'schema' element type 

	<!ATTLIST %schema; ...
		    %nds;
                             xmlns                CDATA                  #IMPLIED ... >
   
since the 'p' parameter entity is defined as

	<!ENTITY % p ''>

in the external subset and the 'schema' parameter entity is defined as

	<!ENTITY % schema '%p;schema'>

in the external subset.

2.  I propose the following changes to remedy this situation. Introduce the 'xmlns-prefix' parameter entity 

	<!ENTITY % xmlns-prefix "%nds; %URIref; #FIXED 'http://www.w3.org/2001/XMLSchema'">  

into the exterior subset (i.e., the "structures" DTD) after the definition of the 'nds' and 'URIref' parameter entities. Then change the 
'%schema;' ATTLIST declaration from

	<!ATTLIST %schema; ...
		    %nds;
                             xmlns                CDATA                  #IMPLIED ... >
to
	<!ATTLIST %schema; ...
		    %xmlns-prefix;
                             xmlns                CDATA                  #IMPLIED ... >

Since "at the Infoset level where schemas operate, the xmlns(:prefix) is NOT an attribute", the first "xmlns" attribute definition can be removed from the '%schema;' ATTLIST by redefining the 'xmlns-prefix' parameter entity as

	<!ENTITY % xmlns-prefix "'">  

in the interior subset (i.e., the DOCTYPE declaration subset).

Donald Gignac	301-227-3348	"gignacda@nswccd.navy.mil"
Received on Tuesday, 20 March 2001 13:43:07 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Sunday, 6 December 2009 18:12:49 GMT