How to correctly import XML namespace
Posted: Fri Mar 24, 2006 7:52 am
I couldn't find an earlier post addressing this question. How does oXygen expect the XML namespace to be imported in XML Schemas that use xml:lang, xml:space, etc? I tried
<xs:import namespace="http://www.w3.org/XML/1998/namespace"/>
which works in some tools, but oXygen seems to require
<xs:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="..."/>
where the schemaLocation points to a copy of "xml.xsd". Is there some reason why oXygen requires an explicit schemaLocation for the XML namespace? A quick read of the XML Schema spec didn't make it clear at all what [b]should[/b] be done, so perhaps it's a matter of choice. However, I'm often offline, so I don't want to use a schemaLocation that is on the Web, while at the same time I don't want to pollute my Schemas with references to local copies of "xml.xsd".
What do you recommend?
Cheers, Tony.
<xs:import namespace="http://www.w3.org/XML/1998/namespace"/>
which works in some tools, but oXygen seems to require
<xs:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="..."/>
where the schemaLocation points to a copy of "xml.xsd". Is there some reason why oXygen requires an explicit schemaLocation for the XML namespace? A quick read of the XML Schema spec didn't make it clear at all what [b]should[/b] be done, so perhaps it's a matter of choice. However, I'm often offline, so I don't want to use a schemaLocation that is on the Web, while at the same time I don't want to pollute my Schemas with references to local copies of "xml.xsd".
What do you recommend?
Cheers, Tony.