- From: Sanjay Dahiya, Noida <sanjay@noida.hcltech.com>
- Date: Wed, 4 Sep 2002 21:25:07 +0530
- To: xmlschema-dev@w3.org
- Message-ID: <E04CF3F88ACBD5119EFE00508BBB212104446CB3@exch-01.noida.hcltech.com>
Hi All Correct me if I am wrong anywhere in the following One can comopse an XML schema using multiple schemas and multiple namespaces so that definitions can be reused (makes perfect sense). For this purpose XML schema can have references to other schemas which might have different namespaces. This is done by 'import' / 'include' tags in the schema definition. Q1: what are the possible ways for doing the same. The instance document reffering to this schema would be validated by loading other schemas and looking for corresponding definitions in those schemas. (good so far) Now XML instance document can also contain references to multiple namespaces and schema using schemaLocation and noNamespaceSchemaLocation ( why multiple ??) Q2: XML document ( which of course must have a root element) would have its definition in one schema only. the child elements which in case refer to other schemas must be refered in the schema only. Second for a validating parser what would be the precise set of rules for locating the definition of an element that is mentioned in the instance document. Now to make things worse each element can refer to a namepace and supply the prefix there itself (No idea where it is going now !!) Q3: now how would the validating parser locate the definition of this element. and Q4: why would someone put a namespace with an element in the instance document and not in its schema ? looks like some of the constructs have been designed with non-validating parsers in mind and others for validating ones. could someone clear things a bit here. thanks and regards Sanjay
Received on Wednesday, 4 September 2002 11:58:28 UTC