RE: XML Schema compliance

Jeni,

I feel that we are very close in me being persuaded. But not there yet
(I am sure you didn't want to hear this :-)

> 
> > This is the modified version. I just changed the "schemaLocation" to
> > point to a file locally. Can you use the file attached? It is the
> > Schema-for-Schemas with a slightly modified xs:element complexType
> > (the "type" attribute has been commented out).
> [snip]
> > Now, if your schema validator says that this is valid, I would argue
> > that it has ignored the xs:element element definition found in the
> > SfS.xsd but has not ignored the xs:element type declaration. Why?
> 
> The schema validator that I used (Xerces-J) reported that the schema
> was valid, as expected. SfS.xsd is used in constructing the infoset
> for my test.xsd schema that's used to validate my instance document;
> it is not used to validate test.xsd to check that it's a valid schema.
> The contents of SfS.xsd have absolutely no bearing on whether the
> validator thinks that test.xsd is valid or not.
> 

OK, thanks. I understand this bit now.

But let's test my understanding...

The XML Schema validator checked test.xsd for XML Schema compliance. It
found the attribute type="xs:element" but ignored the contents. Then, it
started building the new infoset. In the new infoset, xs:element is
valid because there is a type declaration.

What would have happened if type="xs:string"? Does the XML Schema
validator assume that all XML-Schema datatypes are known in the new
infoset?

My problem with this has always been the fact that there are some
datatypes that are seen as built-in in the XML Schema namespace and then
this xs:element appears.

Thank you,
.savas.

Received on Wednesday, 9 July 2003 05:22:13 UTC