Project

General

Profile

1
<!--
2
  * metacatread.html
3
  *
4
  *      Authors: Jivka Bojilova
5
  *    Copyright: 2000 Regents of the University of California and the
6
  *               National Center for Ecological Analysis and Synthesis
7
  *  For Details: http://www.nceas.ucsb.edu/
8
  *      Created: 2000 April 5
9
  *      Version: 0.01
10
  *    File Info: '$Id: metacatread.html 2310 2004-09-21 09:01:22Z jones $'
11
  * 
12
  * October Meeting SDSC, 2000
13
-->
14
<HTML>
15
<HEAD>
16
<TITLE>Metacat</TITLE>
17
<link rel="stylesheet" type="text/css" href="@docrooturl@default.css">
18
</HEAD> 
19
<BODY>
20
  <table width="100%">
21
    <tr>
22
      <td class="tablehead" colspan="2"><p class="label">Reading a Document
23
       from the Database</p></td>
24
       <td class="tablehead" colspan="2" align="right">
25
         <a href="./metacatquery.html">Back</a> | <a href="./metacattour.html">Home</a> | 
26
         <a href="./metacatgetlog.html">Next</a>
27
       </td>
28
    </tr>
29
  </table>
30
  <p>Metacat allows clients to read a document in several different ways,
31
  depending on how the client wants the document returned and how the client
32
  wants to specify the requested document.  </p>
33
  <P> <img alt="architecture diagram of the Metacat read process" 
34
           src="metadataread.gif">  </p>
35
  <p>The documents are requested by the <b>docid</b> servlet parameter by specifying
36
  the document id that you wish to read.<br>
37
  </p>
38
  <p>
39
    Metacat allows the dynamic transformation of read documents through the use
40
    of style-sets.  A style-set is an xsl stylesheet or a group of stylesheets
41
    that are specified in a config file.  The following is an example of a style-set
42
    config file:
43
  </p>
44
  <pre>
45
    &lt;?xml version="1.0"?&gt;
46
    &lt;style-set name="knb"&gt;
47
      &lt;default-style&gt;http://http://server.domain.com/metacat/style/ascii-treeview.xsl&lt;/default-style&gt;
48
      &lt;doctype publicid="-//NCEAS//resultset//EN"&gt;
49
        &lt;target publicid="-//W3C//HTML//EN"&gt;http://http://server.domain.com/metacat/style/resultset.xsl&lt;/target&gt;
50
      &lt;/doctype&gt;
51
      &lt;doctype publicid="-//NCEAS//login//EN"&gt;
52
        &lt;target publicid="-//W3C//HTML//EN"&gt;http://http://server.domain.com/metacat/style/login.xsl&lt;/target&gt;
53
      &lt;/doctype&gt;
54
      &lt;doctype publicid="-//NCEAS//eml-dataset-2.0//EN"&gt;
55
        &lt;target publicid="-//W3C//HTML//EN"&gt;http://http://server.domain.com/metacat/style/eml-dataset-display.xsl&lt;/target&gt;  
56
      &lt;/doctype&gt;
57
      &lt;doctype publicid="-//NCEAS//eml-dataset//EN"&gt;
58
        &lt;target publicid="-//W3C//HTML//EN"&gt;http://http://server.domain.com/metacat/style/eml-dataset-display.xsl&lt;/target&gt;  
59
      &lt;/doctype&gt;
60
      &lt;doctype publicid="-//NCEAS//eml-resource//EN"&gt;
61
        &lt;target publicid="-//W3C//HTML//EN"&gt;http://http://server.domain.com/metacat/style/eml-dataset-display.xsl&lt;/target&gt;  
62
      &lt;/doctype&gt;      
63
      &lt;doctype publicid="-//ecoinformatics.org//eml-dataset-2.0.0beta4//EN"&gt;
64
        &lt;target publicid="-//W3C//HTML//EN"&gt;http://http://server.domain.com/metacat/style/eml-dataset-display.xsl&lt;/target&gt;  
65
      &lt;/doctype&gt;
66
    &lt;/style-set&gt;
67
  </pre>
68

    
69
  <p>
70
    Whenever a read action is requested from Metacat, you can also provide a qformat parameter.
71
    This qformat parameter should be the name of the style-set that you wish to use
72
    to transform the document you are requesting.  Note that the value that you set
73
    qformat to must equal the &lt;style-set&gt; name parameter.
74
  </p>
75
  <p>
76
    A default style-set can be set in the metacat.properties file.  If qformat
77
    is set to 'html', Metacat will use the default.  If qformat is set to 'xml',
78
    Metacat will return the XML document untransformed.
79
  </p>
80
  <br>
81
  <a href="./metacatquery.html">Back</a> | <a href="./metacattour.html">Home</a> | 
82
  <a href="./metacatgetlog.html">Next</a>
83

    
84
</BODY>
85
</HTML>
86

    
(33-33/51)