Hey all,

I have what's probably a n00by question. I was wondering how one handles validation of the XML within an RDF document. For example, let's say there is the XML schema like this:

<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">

  <xs:element name="
BookCatalogue">
    <xs:complexType>
      <xs:sequence>
       
<xs:element ref="Book">
      </xs:sequence>
    </xs:complexType>
  </xs:element>

  <xs:element name="Book">
    <xs:complexType>
      <xs:sequence>
       
<xs:element ref="Title">
       <xs:element name="ISBN" type="xs:unsignedShort">
      </xs:sequence>
    </xs:complexType>
  </xs:element>


  <xs:simpleType name="Title">
    <xs:restriction base="xs:string">
      <xs:minLength value="1"/>
      <xs:maxLength value="40"/>
    </xs:restriction>
  </xs:simpleType>

</xs:schema>

Which allows us to create the following document (which is validated against the schema above):

<BookCatalogue>
  <Book>
    <Title>My Life and Times</Title>
    <ISBN>94303-12021-43892</ISBN>
  </Book>
</BookCatalogue>


And then goes into the following RDF document:

<?xml version="1.0"?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
  xmlns:nb="http://n00by/aquestion#">
  <rdf:Description rdf:about="http://www.xfront.com#BookCatalogue.xml">
    <nb:Title>Constructing Intelligent Agents Using Java</nb:Title>

    <nb:ISBN>94303-12021-43892</nb:ISBN>
  </rdf:Description
</rdf:RDF>



My question with all of that is how do we get past the fact that the XML Schema validation is going to fail because we now have unknown attributes into the tag set and unknown elements in the tag set. Or is this not an issue because this RDF document is really the result of a transformation done by an RDF API (kind of like XSL-FO is really the result of taking some XML, running it through some XSLT document which results in the XSL-FO document) and all this is done *after* the validation using XML Schema?

Thanks in advance for any help!