OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   Re: [xml-dev] XML:lang, clarification demanded

[ Lists Home | Date Index | Thread Index ]

From: "Kris Vanhoutte" <kris.vanhoutte@ctparadigm.be>

> I think it IS a specific XML:lang-problem.  I created a Xschema with only the following namespace in it:
    <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"; 
        elementFormDefault="qualified" attributeFormDefault="qualified">
> I pulled out the networkcable, tried to validate and received the message "the xml-document is valid 
> against the Xschema".
 
XML Schema has an unsettling property (for a spec that places so much emphasis on uniform results
of validation) that it is entirely up to the schema processor where it sources *any* schema from.

E.g. A schema processor can look up its own list of schemas in preference to the schemaLocation "hint".
Or it could try the schemaLocation first, then use the built-in schema. Or it could ignore the schemaLocation
hints altogether.  All that is allowed, and application dependent.   So one schema processor might work
if there is an unreachable include by providing some fallback, another might fail.

If there is an unreachable component and the instance being validated has no occurrences of that namespace,
then I think there is no error invovled. If there is an information item found for a namespace whose
component is missing, then that will be noted: see http://www.w3.org/TR/xmlschema-1/#conformance-missing
So if your instance document does not use any xml: attributes, and the schema does not have that import
statement, there certainly should be no validity error.

I don't see anything in the XML Schemas spec that says a schema processor must have any built-in knowledge
of the XML namespace at the component level (obviously it does at the XML surface). So I expect it is
correct that if your schema allows xml: attributes and is a closed schema (not allowing undeclared foreign
attributes) it will generally have to provide an explicit declaration. 

Cheers
Rick Jelliffe




 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS