Add documentation - man page xquery.3mp
[mp-xquery-moved-to-github.git] / doc / xquery.xml
diff --git a/doc/xquery.xml b/doc/xquery.xml
new file mode 100644 (file)
index 0000000..4178ad8
--- /dev/null
@@ -0,0 +1,98 @@
+<!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>&lt;script name="name"&gt;</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>&lt;record name="var"&gt;</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>&lt;variable name="name" value="value"/&gt;</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:
+-->