[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: XML:lang, clarification demanded
From: "Kris Vanhoutte" <kris.vanhoutte@c...> > 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
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|