Rules (here described with the Namespace Routing Language) relate namespaces to schemas:
<rules xmlns="http://www.thaiopensource.com/validate/nrl"> <namespace ns="http://www.w3.org/1999/xhtml" match="elements attributes"> <validate schema="xhtml.rng"/> </namespace> <namespace ns="http://www.example.org/its" match="attributes"> <validate schema="its.rnc" schemaType="application/x-rnc"/> </namespace> </rules>
According to the rules, documents are seperated into element and attribute sections, e.g. for ITS and XHTML:
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:its="http://www.example.org/its" its:translate="yes"> <head><title its:translate="no">... <its:span>...</its:span> </html>
The three ITS sections are validated against a schema for ITS:
namespace its = "http://www.example.org/its"
attribute its:translate { "yes" | "no" }?
element its:span { text }