--- /dev/null
+
+.PHONY: check all
+.SUFFIXES: .3mp .xml .1
+
+XSLTPROC_COMPILE = xsltproc --xinclude -path "."
+HTML_COMPILE = $(XSLTPROC_COMPILE) id.htmlhelp.xsl
+MAN_COMPILE = $(XSLTPROC_COMPILE) id.man.xsl
+REFFILES = xquery.xml
+MANFILES=xquery.3mp
+
+XMLFILES=book.xml manref.xml
+
+all: $(MANFILES)
+
+index.html: $(XMLFILES)
+ $(HTML_COMPILE) book.xml
+
+manref.xml: $(REFFILES)
+ rm -f manref.xml
+ for i in $(REFFILES); do \
+ xsltproc stripref.xsl $$i | sed 1d >>manref.xml; \
+ done
+
+.xml.3mp:
+ $(MAN_COMPILE) $<
+
+clean:
+ rm -f *.html *.pdf manref.xml *.hhp *.hhc $(MANFILES)
+
+distclean: clean
+
+check: all
+
--- /dev/null
+# Metaproxy XML config file schema
+
+namespace mp = "http://indexdata.com/metaproxy"
+
+filter_xquery =
+ attribute type { "xquery" },
+ attribute id { xsd:NCName }?,
+ attribute name { xsd:NCName }?,
+ element mp:script {
+ attribute name { xsd:string },
+ },
+ element mp:record {
+ attribute name { xsd:string },
+ },
+ element mp:variable {
+ attribute name { xsd:string },
+ attribute value { xsd:string },
+ }*
+
--- /dev/null
+<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ version="1.0">
+
+<xsl:import href="http://docbook.sourceforge.net/release/xsl/current/htmlhelp/htmlhelp.xsl" />
+
+<xsl:template name="body.attributes">
+ <link rel="stylesheet" type="text/css" href="style.css"/>
+</xsl:template>
+<xsl:variable name="suppress.navigation">0</xsl:variable>
+<xsl:variable name="use.id.as.filename">1</xsl:variable>
+<xsl:variable name="generate.book.toc">1</xsl:variable>
+<xsl:variable name="toc.section.depth">3</xsl:variable>
+<xsl:variable name="generate.toc.section.depth">3</xsl:variable>
+<xsl:variable name="section.autolabel">1</xsl:variable>
+
+</xsl:stylesheet>
+
+
--- /dev/null
+<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.4//EN"
+ "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
+]>
+<refentry id="xquery">
+ <refentryinfo>
+ <productname>Metaproxy XQuery module</productname>
+ <info><orgname>Index Data</orgname></info>
+ </refentryinfo>
+
+ <refmeta>
+ <refentrytitle>xquery</refentrytitle>
+ <manvolnum>3mp</manvolnum>
+ <refmiscinfo class="manual">Metaproxy Module</refmiscinfo>
+ </refmeta>
+
+ <refnamediv>
+ <refname>xquery</refname>
+ <refpurpose>
+ Metaproxy Module for performing record transform using XQuery
+ </refpurpose>
+ </refnamediv>
+
+ <refsect1><title>DESCRIPTION</title>
+ <para>
+ This filter performs record transforms on XML records using
+ XQuery. The module is based on Zorba.
+ </para>
+ <para>
+ Configurable values:
+ <variablelist>
+ <varlistentry><term><script name="name"></term>
+ <listitem>
+ <para>
+ The full path of the XQuery script to be invoked.
+ This is required and should be set exactly once.
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry><term><record name="var"></term>
+ <listitem>
+ <para>
+ The name of the XQUery variable where the input XML record
+ is stored.
+ This is required and should be set exactly once.
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry><term><variable name="name" value="value"/></term>
+ <listitem>
+ <para>
+ Sets XQuery variable name to value. This is set before each
+ record is converted. This setting may be repeated to set multiple
+ variables.
+ </para>
+ </listitem>
+ </varlistentry>
+ </variablelist>
+ </para>
+ </refsect1>
+
+ <refsect1><title>SCHEMA</title>
+ <literallayout><xi:include
+ xi:href="filter_xquery.rnc"
+ xi:parse="text"
+ xmlns:xi="http://www.w3.org/2001/XInclude" />
+ </literallayout>
+ </refsect1>
+
+ <refsect1><title>EXAMPLES</title>
+ <para>
+ Configuration:
+ <screen><![CDATA[
+ <filter type="session_shared">
+ <resultset ttl="10" max="3" restart="true"/>
+ <session ttl="30" max="100"/>
+ </filter>
+]]>
+ </screen>
+ </para>
+ </refsect1>
+
+ <refsect1><title>SEE ALSO</title>
+ <para>
+ <citerefentry>
+ <refentrytitle>metaproxy</refentrytitle>
+ <manvolnum>1</manvolnum>
+ </citerefentry>
+ </para>
+ </refsect1>
+
+</refentry>
+
+<!-- Keep this comment at the end of the file
+Local variables:
+mode: nxml
+nxml-child-indent: 1
+End:
+-->