Commit b5227f63 authored by Sylvain Schmitz's avatar Sylvain Schmitz

put schema meta-data in XML format

parent 4e1f4def
<?xml version="1.0"?>
<!-- Meta-data about the implemented RelaxNG schemas. -->
<schemas>
<schema file="xpath-2.0-core.rnc"
name="2.0-core"
color="#ccebc5">
<bib>
<author>Balder ten Cate</author>
<author>Carsten Lutz</author>
<title>The complexity of query containment in expressive
fragments of XPath 2.0</title>
<venue volume="56" issue="6" article="31" abbr="JACM">Journal of
the ACM</venue>
<year>2009</year>
<doi>10.1145/1568318.1568321</doi>
</bib>
</schema>
<schema file="xpath-1.0-core.rnc"
name="core"
color="#ccebc5">
<bib>
<author>Michael Benedikt</author>
<author>Christoph Koch</author>
<title>XPath Leashed</title>
<venue volume="41" issue="1" article="3">ACM Computing Surveys</venue>
<year>2009</year>
<doi>10.1145/1456650.1456653</doi>
</bib>
</schema>
<schema file="xpath-1.0-minimal.rnc"
name="minimal"
color="#ccebc5">
<bib>
<author>Michael Benedikt</author>
<author>Christoph Koch</author>
<title>XPath Leashed</title>
<venue volume="41" issue="1" article="3">ACM Computing Surveys</venue>
<year>2009</year>
<doi>10.1145/1456650.1456653</doi>
</bib>
</schema>
<schema file="xpath-1.0-downward.rnc"
name="downward"
color="#b3cde3">
<bib>
<author>Diego Figueira</author>
<title>Decidability of Downward XPath</title>
<venue volume="13" issue="4" article="34" abbr="ToCL">ACM Transactions on
Computational Logic</venue>
<year>2012</year>
<doi>10.1145/2362355.2362362</doi>
</bib>
</schema>
<schema file="xpath-1.0-forward.rnc"
name="forward"
color="#b3cde3">
<bib>
<author>Diego Figueira</author>
<title>Alternating Register Automata on Finite Data Words and Trees</title>
<venue volume="8" issue="1" article="22" abbr="LMCS">Logical Methods in
Computer Science</venue>
<year>2012</year>
<doi>10.2168/LMCS-8(1:22)2012</doi>
</bib>
</schema>
<schema file="xpath-1.0-vertical.rnc"
name="vertical"
color="#b3cde3">
<bib>
<author>Diego Figueira</author>
<author>Luc Segoufin</author>
<title>Bottom-up automata on data trees and vertical XPath</title>
<venue volume="9" series="LIPIcs" pages="93--109"
publisher="LZI" abbr="STACS'11">Proceedings of the 28th Annual
Symposium on Theoretical Aspects of Computer Science</venue>
<year>2011</year>
<doi>10.4230/LIPIcs.STACS.2011.93</doi>
</bib>
</schema>
<schema file="xpath-patterns.rnc"
name="patterns"
color="#b3cde3">
<bib>
<author>Wojciech Czerwinski</author>
<author>Claire David</author>
<author>Filip Murlak</author>
<author>Paweł Parys</author>
<title>Reasoning About Integrity Constraints for Tree-Structured
Data</title>
<venue volume="48" series="LIPIcs" article="20" publisher="LZI"
abbr="ICDT'16">Proceedings of the 19th International Conference
on Database Theory</venue>
<year>2016</year>
<doi>10.4230/LIPIcs.ICDT.2016.20</doi>
</bib>
</schema>
<schema file="xpath-1.0.rnc"
name="1.0"
color="#decbe4">
<bib>
<title>XML Path Language (XPath), Version 1.0</title>
<venue>W3C Recommendation</venue>
<year>1999</year>
<href>https://www.w3.org/TR/xpath/</href>
</bib>
</schema>
<schema file="xpath-1.0-eval.rnc"
name="eval"
color="#fbb4ae"
href="">
<bib>
<author>Mikołaj Bojańczyk</author>
<author>Paweł Parys</author>
<title>XPath evaluation in linear time</title>
<venue volume="58" issue="4" article="17" abbr="JACM">Journal of
the ACM</venue>
<year>2011</year>
<doi>10.1145/1989727.1989731</doi>
</bib>
</schema>
<schema file="xpath-hybrid.rnc"
name="hybrid"
color="#fed9a6">
<bib>
<author>Mikołaj Bojańczyk</author>
<author>Anca Muscholl</author>
<author>Thomas Schwentick</author>
<author>Luc Segoufin</author>
<title>Two-variable Logic on Data Trees and XML Reasoning</title>
<venue volume="56" issue="3" article="13" abbr="JACM">Journal of
the ACM</venue>
<year>2009</year>
<doi>10.1145/1516512.1516515</doi>
</bib>
</schema>
</schemas>
\ No newline at end of file
......@@ -4,7 +4,7 @@
<xsl:output method="text"/>
<xsl:param name="fragments"
select="('xpath-2.0-core.rnc', 'xpath-1.0-core.rnc', 'xpath-1.0-minimal.rnc', 'xpath-1.0-downward.rnc', 'xpath-1.0-forward.rnc', 'xpath-1.0-vertical.rnc', 'xpath-patterns.rnc', 'xpath-1.0.rnc', 'xpath-1.0-eval.rnc', 'xpath-hybrid.rnc')"/>
select="document('../relaxng/meta.xml')//schema"/>
<xsl:param name="nexamples" select="15"/>
......@@ -16,7 +16,7 @@
</xsl:text>
<xsl:for-each select="$fragments">
<xsl:call-template name="fragment">
<xsl:with-param name="f" select="string(current())"/>
<xsl:with-param name="f" select="current()"/>
<xsl:with-param name="root" select="$root"/>
</xsl:call-template>
<xsl:text>
......@@ -28,7 +28,7 @@
<xsl:text>[</xsl:text>
<xsl:for-each select="$fragments">
<xsl:call-template name="line">
<xsl:with-param name="source" select="string(current())"/>
<xsl:with-param name="source" select="current()"/>
<xsl:with-param name="root" select="$root"/>
</xsl:call-template>
</xsl:for-each>
......@@ -44,7 +44,7 @@
<xsl:for-each select="$fragments">
<xsl:call-template name="entry">
<xsl:with-param name="source" select="$source"/>
<xsl:with-param name="target" select="string(current())"/>
<xsl:with-param name="target" select="current()"/>
<xsl:with-param name="root" select="$root"/>
</xsl:call-template>
</xsl:for-each>
......@@ -59,7 +59,7 @@
<xsl:param name="source"/>
<xsl:param name="target"/>
<xsl:param name="root"/>
<xsl:variable name="examples" select="$root//xpath[validation[@schema=$source and @valid='yes'] and validation[@schema=$target and @valid='no']]"/>
<xsl:variable name="examples" select="$root//xpath[validation[@schema=$source/@file and @valid='yes'] and validation[@schema=$target/@file and @valid='no'] and ast/descendant::*[local-name() = 'xpathAxis']]"/>
<xsl:text>{ "z": </xsl:text><xsl:value-of select="count($examples)"/>
<xsl:if test="$examples">
<xsl:text>, "examples": [</xsl:text>
......@@ -83,33 +83,10 @@
<xsl:template name="fragment">
<xsl:param name="f"/>
<xsl:param name="root"/>
<xsl:variable name="name" select="substring-before(substring-after($f,'xpath-'),'.rnc')"/>
<xsl:choose>
<xsl:when test="matches($name,'1.0-.*')">
<xsl:value-of select="substring-after($name,'1.0-')"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="$name"/>
</xsl:otherwise>
</xsl:choose>
<xsl:choose>
<xsl:when test="matches($f,'.*-(core|minimal).rnc')">
<xsl:text>,#ccebc5,</xsl:text>
</xsl:when>
<xsl:when test="matches($f,'.*-(downward|forward|vertical|patterns).rnc')">
<xsl:text>,#b3cde3,</xsl:text>
</xsl:when>
<xsl:when test="matches($f,'.*-(data|eval|leashed).rnc')">
<xsl:text>,#fbb4ae,</xsl:text>
</xsl:when>
<xsl:when test="matches($f,'.*-[123].0.rnc')">
<xsl:text>,#decbe4,</xsl:text>
</xsl:when>
<xsl:otherwise>
<xsl:text>,#fed9a6,</xsl:text>
</xsl:otherwise>
</xsl:choose>
<xsl:value-of select="count($root//xpath[validation[@schema=$f and @valid='yes']])"/>
<xsl:value-of select="$f/@name"/>
<xsl:text>,</xsl:text>
<xsl:value-of select="$f/@color"/>
<xsl:text>,</xsl:text>
<xsl:value-of select="count($root//xpath[validation[@schema=$f/@file and @valid='yes'] and ast/descendant::*[local-name() = 'xpathAxis']])"/>
</xsl:template>
</xsl:stylesheet>
\ No newline at end of file
</xsl:stylesheet>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment