[xml] relax ng support in libxml2?
- From: David Tolpin <dvd davidashen net>
- To: xml gnome org
- Subject: [xml] relax ng support in libxml2?
- Date: Tue, 30 Dec 2003 02:59:26 +0400 (AMT)
Hi,
xmllint: using libxml version 20604
compiled with: DTDValid FTP HTTP HTML C14N Catalog XPath XPointer XInclude Unicode Regexps Automata
Schemas
fails to validate
<stylesheet xmlns:foo="http://example.com/foo" xmlns="http://www.w3.org/1999/XSL/Transform" version="1.0">
<template>
<foo:x a="b"/>
</template>
</stylesheet>
against
<grammar xmlns:xsl="http://www.w3.org/1999/XSL/Transform" ns="http://www.w3.org/1999/XSL/Transform"
xmlns="http://relaxng.org/ns/structure/1.0" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
<start>
<element name="stylesheet">
<attribute name="version"><text/></attribute>
<zeroOrMore>
<ref name="template.element"/>
</zeroOrMore>
</element>
</start>
<define name="template.element">
<element name="template">
<ref name="template.model"/>
</element>
</define>
<define name="template.model">
<zeroOrMore>
<choice>
<ref name="template.element"/>
<ref name="literal-result-element"/>
<text/>
</choice>
</zeroOrMore>
</define>
<define name="literal-result-element">
<element>
<anyName>
<except>
<nsName/>
</except>
</anyName>
<ref name="literal-result-element.atts"/>
<ref name="template.model"/>
</element>
</define>
<define name="literal-result-element.atts">
<zeroOrMore>
<choice>
<attribute>
<anyName>
<except>
<nsName/>
</except>
</anyName>
<data type="string"/>
</attribute>
</choice>
</zeroOrMore>
</define>
</grammar>
complaining, that
/home/dvd/work/PreTI/CImpl/admon.xsl:5: element x: Relax-NG validity error : Did not expect element x there
/home/dvd/work/PreTI/CImpl/admon.xsl fails to validate
David Tolpin
http://davidashen.net/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]