File: tutorial-oai-sru-present.html

package info (click to toggle)
idzebra 2.2.10-1
  • links: PTS, VCS
  • area: main
  • in suites:
  • size: 10,644 kB
  • sloc: ansic: 54,389; xml: 27,054; sh: 6,211; makefile: 1,099; perl: 210; tcl: 64
file content (44 lines) | stat: -rw-r--r-- 5,103 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
<html><head><meta charset="ISO-8859-1"><title>3.Presenting search results in different formats</title><meta name="generator" content="DocBook XSL Stylesheets Vsnapshot"><link rel="home" href="index.html" title="Zebra - User's Guide and Reference"><link rel="up" href="tutorial.html" title="Chapter3.Tutorial"><link rel="prev" href="tutorial-oai-sru-pqf.html" title="2.Searching the OAI database by web service"><link rel="next" href="tutorial-oai-sru-searches.html" title="4.More interesting searches"></head><body><link rel="stylesheet" type="text/css" href="common/style1.css"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">3.Presenting search results in different formats</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="tutorial-oai-sru-pqf.html">Prev</a></td><th width="60%" align="center">Chapter3.Tutorial</th><td width="20%" align="right"><a accesskey="n" href="tutorial-oai-sru-searches.html">Next</a></td></tr></table><hr></div><div class="sect1"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="tutorial-oai-sru-present"></a>3.Presenting search results in different formats</h2></div></div></div><p>
    <span class="application">Zebra</span> uses <acronym class="acronym">XSLT</acronym> stylesheets for both <acronym class="acronym">XML</acronym>record
    indexing and
    display retrieval. In this example installation, they are two
    retrieval schema's defined in
    <code class="literal">conf/dom-conf.xml</code>:
    the <code class="literal">dc</code> schema implemented in
    <code class="literal">conf/oai2dc.xsl</code>, and
    the <code class="literal">zebra</code> schema implemented in
    <code class="literal">conf/oai2zebra.xsl</code>.
    The URLs for accessing both are the same, except for the different
    value of the <code class="literal">recordSchema</code> parameter:
    <a class="ulink" href="http://localhost:9999/?version=1.1&amp;operation=searchRetrieve&amp;x-pquery=the&amp;startRecord=1&amp;maximumRecords=1&amp;recordSchema=dc" target="_top">
     http://localhost:9999/?version=1.1&amp;operation=searchRetrieve&amp;x-pquery=the&amp;startRecord=1&amp;maximumRecords=1&amp;recordSchema=dc
    </a>
    and
    <a class="ulink" href="http://localhost:9999/?version=1.1&amp;operation=searchRetrieve&amp;x-pquery=the&amp;startRecord=1&amp;maximumRecords=1&amp;recordSchema=zebra" target="_top">
     http://localhost:9999/?version=1.1&amp;operation=searchRetrieve&amp;x-pquery=the&amp;startRecord=1&amp;maximumRecords=1&amp;recordSchema=zebra
    </a>
    For the curious, one can see that the <acronym class="acronym">XSLT</acronym> transformations
    really do the magic.
    </p><pre class="screen">
     xsltproc conf/oai2dc.xsl data/debug-record.xml
     xsltproc conf/oai2zebra.xsl data/debug-record.xml
    </pre><p>
    Notice also that the <span class="application">Zebra</span> specific parameters are injected by
    the engine when retrieving data, therefore some of the attributes
    in the <code class="literal">zebra</code> retrieval schema are not filled
    when running the transformation from the command line.
   </p><p>
    In addition to the user defined retrieval schema's one can  always
    choose from many  build-in schema's. In case one is only
    interested in the <span class="application">Zebra</span> internal metadata about a certain
    record, one uses the <code class="literal">zebra::meta</code> schema.
    <a class="ulink" href="http://localhost:9999/?version=1.1&amp;operation=searchRetrieve&amp;x-pquery=the&amp;startRecord=1&amp;maximumRecords=1&amp;recordSchema=zebra::meta" target="_top">
     http://localhost:9999/?version=1.1&amp;operation=searchRetrieve&amp;x-pquery=the&amp;startRecord=1&amp;maximumRecords=1&amp;recordSchema=zebra::meta
    </a>
   </p><p>
    The <code class="literal">zebra::data</code> schema is used to retrieve the
    original stored <acronym class="acronym">OAI</acronym> <acronym class="acronym">XML</acronym> record.
    <a class="ulink" href="http://localhost:9999/?version=1.1&amp;operation=searchRetrieve&amp;x-pquery=the&amp;startRecord=1&amp;maximumRecords=1&amp;recordSchema=zebra::data" target="_top">
     http://localhost:9999/?version=1.1&amp;operation=searchRetrieve&amp;x-pquery=the&amp;startRecord=1&amp;maximumRecords=1&amp;recordSchema=zebra::data
    </a>
   </p></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="tutorial-oai-sru-pqf.html">Prev</a></td><td width="20%" align="center"><a accesskey="u" href="tutorial.html">Up</a></td><td width="40%" align="right"><a accesskey="n" href="tutorial-oai-sru-searches.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">2.Searching the <acronym class="acronym">OAI</acronym> database by web service</td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top">4.More interesting searches</td></tr></table></div></body></html>