Project

General

Profile

« Previous | Next » 

Revision 515

Added by Matt Jones over 23 years ago

Updated the Javadoc documentation so that the current release can be provided
on the web site.

View differences:

MetaCatServlet.html
2 2
<!--NewPage-->
3 3
<HTML>
4 4
<HEAD>
5
<!-- Generated by javadoc on Mon Jun 26 20:52:07 AKDT 2000 -->
5
<!-- Generated by javadoc on Tue Nov 07 20:14:05 PST 2000 -->
6 6
<TITLE>
7 7
MetaCat API: Class  MetaCatServlet
8 8
</TITLE>
......
18 18
<A NAME="navbar_top_firstrow"><!-- --></A>
19 19
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">
20 20
  <TR ALIGN="center" VALIGN="top">
21
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT ID="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
21
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
22 22
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
23
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/MetaCatServlet.html"><FONT ID="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
24
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT ID="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
25
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT ID="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
26
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT ID="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
27
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT ID="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
23
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/MetaCatServlet.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
24
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
25
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
26
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
27
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
28 28
  </TR>
29 29
</TABLE>
30 30
</TD>
......
36 36
<TR>
37 37
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
38 38
&nbsp;<A HREF="../../../../edu/ucsb/nceas/metacat/ElementNode.html"><B>PREV CLASS</B></A>&nbsp;
39
&nbsp;<A HREF="../../../../edu/ucsb/nceas/metacat/MetaCatUtil.html"><B>NEXT CLASS</B></A></FONT></TD>
39
&nbsp;<A HREF="../../../../edu/ucsb/nceas/metacat/MetaCatSession.html"><B>NEXT CLASS</B></A></FONT></TD>
40 40
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
41 41
  <A HREF="../../../../index.html" TARGET="_top"><B>FRAMES</B></A>  &nbsp;
42 42
&nbsp;<A HREF="MetaCatServlet.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD>
......
84 84
 query -- actual query text (to go with 'action=query' or 'action=squery')<br>
85 85
 valtext -- XML text to be validated<br>
86 86
 action=getdatadoc -- retreive a stored datadocument<br>
87
 action=getdoctypes -- retreive all doctypes (publicID)<br>
88
 action=getdataguide -- retreive a Data Guide<br>
87 89
 datadoc -- data document name (id)<br>
88 90
 <p>
89 91
 The particular combination of parameters that are valid for each 
......
125 127
</TR>
126 128
<TR BGCOLOR="white" CLASS="TableRowColor">
127 129
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
130
<CODE>protected &nbsp;java.lang.String</CODE></FONT></TD>
131
<TD><CODE><B><A HREF="../../../../edu/ucsb/nceas/metacat/MetaCatServlet.html#createResultDocument(java.util.Hashtable, java.lang.String)">createResultDocument</A></B>(java.util.Hashtable&nbsp;doclist,
132
                     java.lang.String&nbsp;xmlquery)</CODE>
133

  
134
<BR>
135
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Transforms a hashtable of documents to an xml or html result.</TD>
136
</TR>
137
<TR BGCOLOR="white" CLASS="TableRowColor">
138
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
139
<CODE>protected &nbsp;java.lang.String</CODE></FONT></TD>
140
<TD><CODE><B><A HREF="../../../../edu/ucsb/nceas/metacat/MetaCatServlet.html#decodeMouseAction(java.util.Hashtable)">decodeMouseAction</A></B>(java.util.Hashtable&nbsp;params)</CODE>
141

  
142
<BR>
143
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;decodes the mouse click information coming from the client.</TD>
144
</TR>
145
<TR BGCOLOR="white" CLASS="TableRowColor">
146
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
128 147
<CODE>&nbsp;void</CODE></FONT></TD>
148
<TD><CODE><B><A HREF="../../../../edu/ucsb/nceas/metacat/MetaCatServlet.html#destroy()">destroy</A></B>()</CODE>
149

  
150
<BR>
151
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Close all db connections from the pool</TD>
152
</TR>
153
<TR BGCOLOR="white" CLASS="TableRowColor">
154
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
155
<CODE>&nbsp;void</CODE></FONT></TD>
129 156
<TD><CODE><B><A HREF="../../../../edu/ucsb/nceas/metacat/MetaCatServlet.html#doGet(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)">doGet</A></B>(javax.servlet.http.HttpServletRequest&nbsp;request,
130 157
      javax.servlet.http.HttpServletResponse&nbsp;response)</CODE>
131 158

  
......
143 170
</TR>
144 171
<TR BGCOLOR="white" CLASS="TableRowColor">
145 172
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
173
<CODE>protected &nbsp;void</CODE></FONT></TD>
174
<TD><CODE><B><A HREF="../../../../edu/ucsb/nceas/metacat/MetaCatServlet.html#handleQuery(java.io.PrintWriter, java.util.Hashtable, javax.servlet.http.HttpServletResponse, java.lang.String, java.lang.String)">handleQuery</A></B>(java.io.PrintWriter&nbsp;out,
175
            java.util.Hashtable&nbsp;params,
176
            javax.servlet.http.HttpServletResponse&nbsp;response,
177
            java.lang.String&nbsp;user,
178
            java.lang.String&nbsp;group)</CODE>
179

  
180
<BR>
181
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Create the xml query, execute it and display the results.</TD>
182
</TR>
183
<TR BGCOLOR="white" CLASS="TableRowColor">
184
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
185
<CODE>protected &nbsp;void</CODE></FONT></TD>
186
<TD><CODE><B><A HREF="../../../../edu/ucsb/nceas/metacat/MetaCatServlet.html#handleSQuery(java.io.PrintWriter, java.util.Hashtable, javax.servlet.http.HttpServletResponse, java.lang.String, java.lang.String)">handleSQuery</A></B>(java.io.PrintWriter&nbsp;out,
187
             java.util.Hashtable&nbsp;params,
188
             javax.servlet.http.HttpServletResponse&nbsp;response,
189
             java.lang.String&nbsp;user,
190
             java.lang.String&nbsp;group)</CODE>
191

  
192
<BR>
193
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Retreive the squery xml, execute it and display it</TD>
194
</TR>
195
<TR BGCOLOR="white" CLASS="TableRowColor">
196
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
146 197
<CODE>&nbsp;void</CODE></FONT></TD>
147 198
<TD><CODE><B><A HREF="../../../../edu/ucsb/nceas/metacat/MetaCatServlet.html#init(javax.servlet.ServletConfig)">init</A></B>(javax.servlet.ServletConfig&nbsp;config)</CODE>
148 199

  
149 200
<BR>
150 201
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Initialize the servlet by creating appropriate database connections</TD>
151 202
</TR>
203
<TR BGCOLOR="white" CLASS="TableRowColor">
204
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
205
<CODE>protected &nbsp;java.lang.String</CODE></FONT></TD>
206
<TD><CODE><B><A HREF="../../../../edu/ucsb/nceas/metacat/MetaCatServlet.html#transformQuery(java.util.Hashtable)">transformQuery</A></B>(java.util.Hashtable&nbsp;params)</CODE>
207

  
208
<BR>
209
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Removes the <?xml version="x"?> tag from the beginning of xmlquery
210
 so it can properly be placed in the <query> tag of the resultset.</TD>
211
</TR>
212
<TR BGCOLOR="white" CLASS="TableRowColor">
213
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
214
<CODE>protected &nbsp;java.lang.String</CODE></FONT></TD>
215
<TD><CODE><B><A HREF="../../../../edu/ucsb/nceas/metacat/MetaCatServlet.html#transformQuery(java.lang.String)">transformQuery</A></B>(java.lang.String&nbsp;xmlquery)</CODE>
216

  
217
<BR>
218
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;removes the <?xml version="1.0"?> tag from the beginning.</TD>
219
</TR>
220
<TR BGCOLOR="white" CLASS="TableRowColor">
221
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
222
<CODE>protected &nbsp;void</CODE></FONT></TD>
223
<TD><CODE><B><A HREF="../../../../edu/ucsb/nceas/metacat/MetaCatServlet.html#transformResultset(java.lang.String, javax.servlet.http.HttpServletResponse, java.io.PrintWriter)">transformResultset</A></B>(java.lang.String&nbsp;resultdoc,
224
                   javax.servlet.http.HttpServletResponse&nbsp;response,
225
                   java.io.PrintWriter&nbsp;out)</CODE>
226

  
227
<BR>
228
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Transorms an xml resultset document to html and sends it to the browser</TD>
229
</TR>
152 230
</TABLE>
153 231
&nbsp;
154 232
<P>
......
192 270
<DD>Initialize the servlet by creating appropriate database connections</DL>
193 271
<HR>
194 272

  
273
<A NAME="destroy()"><!-- --></A><H3>
274
destroy</H3>
275
<PRE>
276
public void <B>destroy</B>()</PRE>
277
<DL>
278
<DD>Close all db connections from the pool</DL>
279
<HR>
280

  
195 281
<A NAME="doGet(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)"><!-- --></A><H3>
196 282
doGet</H3>
197 283
<PRE>
......
212 298
                   java.io.IOException</PRE>
213 299
<DL>
214 300
<DD>Handle "POST" method requests from HTTP clients</DL>
301
<HR>
302

  
303
<A NAME="decodeMouseAction(java.util.Hashtable)"><!-- --></A><H3>
304
decodeMouseAction</H3>
305
<PRE>
306
protected java.lang.String <B>decodeMouseAction</B>(java.util.Hashtable&nbsp;params)</PRE>
307
<DL>
308
<DD>decodes the mouse click information coming from the client.
309
 This function may be overwritten to provide specific functionality
310
 for different applications.<DD><DL>
311
<DT><B>Parameters:</B><DD><CODE>params</CODE> - the parameters from the CGI<DT><B>Returns:</B><DD>action the action to be performed or "error" if an error was
312
 generated</DL>
313
</DD>
314
</DL>
315
<HR>
316

  
317
<A NAME="handleSQuery(java.io.PrintWriter, java.util.Hashtable, javax.servlet.http.HttpServletResponse, java.lang.String, java.lang.String)"><!-- --></A><H3>
318
handleSQuery</H3>
319
<PRE>
320
protected void <B>handleSQuery</B>(java.io.PrintWriter&nbsp;out,
321
                            java.util.Hashtable&nbsp;params,
322
                            javax.servlet.http.HttpServletResponse&nbsp;response,
323
                            java.lang.String&nbsp;user,
324
                            java.lang.String&nbsp;group)</PRE>
325
<DL>
326
<DD>Retreive the squery xml, execute it and display it<DD><DL>
327
<DT><B>Parameters:</B><DD><CODE>out</CODE> - the output stream to the client<DD><CODE>params</CODE> - the Hashtable of parameters that should be included
328
 in the squery.<DD><CODE>response</CODE> - the response object linked to the client<DD><CODE>conn</CODE> - the database connection</DL>
329
</DD>
330
</DL>
331
<HR>
332

  
333
<A NAME="handleQuery(java.io.PrintWriter, java.util.Hashtable, javax.servlet.http.HttpServletResponse, java.lang.String, java.lang.String)"><!-- --></A><H3>
334
handleQuery</H3>
335
<PRE>
336
protected void <B>handleQuery</B>(java.io.PrintWriter&nbsp;out,
337
                           java.util.Hashtable&nbsp;params,
338
                           javax.servlet.http.HttpServletResponse&nbsp;response,
339
                           java.lang.String&nbsp;user,
340
                           java.lang.String&nbsp;group)</PRE>
341
<DL>
342
<DD>Create the xml query, execute it and display the results.<DD><DL>
343
<DT><B>Parameters:</B><DD><CODE>out</CODE> - the output stream to the client<DD><CODE>params</CODE> - the Hashtable of parameters that should be included
344
 in the squery.<DD><CODE>response</CODE> - the response object linked to the client</DL>
345
</DD>
346
</DL>
347
<HR>
348

  
349
<A NAME="transformQuery(java.util.Hashtable)"><!-- --></A><H3>
350
transformQuery</H3>
351
<PRE>
352
protected java.lang.String <B>transformQuery</B>(java.util.Hashtable&nbsp;params)</PRE>
353
<DL>
354
<DD>Removes the <?xml version="x"?> tag from the beginning of xmlquery
355
 so it can properly be placed in the <query> tag of the resultset.
356
 This method is overwritable so that other applications can customize
357
 the structure of what is in the <query> tag.<DD><DL>
358
<DT><B>Parameters:</B><DD><CODE>xmlquery</CODE> - is the query to remove the <?xml version="x"?> tag from.</DL>
359
</DD>
360
</DL>
361
<HR>
362

  
363
<A NAME="transformQuery(java.lang.String)"><!-- --></A><H3>
364
transformQuery</H3>
365
<PRE>
366
protected java.lang.String <B>transformQuery</B>(java.lang.String&nbsp;xmlquery)</PRE>
367
<DL>
368
<DD>removes the <?xml version="1.0"?> tag from the beginning.  This takes a
369
 string as a param instead of a hashtable.<DD><DL>
370
<DT><B>Parameters:</B><DD><CODE>xmlquery</CODE> - a string representing a query.</DL>
371
</DD>
372
</DL>
373
<HR>
374

  
375
<A NAME="transformResultset(java.lang.String, javax.servlet.http.HttpServletResponse, java.io.PrintWriter)"><!-- --></A><H3>
376
transformResultset</H3>
377
<PRE>
378
protected void <B>transformResultset</B>(java.lang.String&nbsp;resultdoc,
379
                                  javax.servlet.http.HttpServletResponse&nbsp;response,
380
                                  java.io.PrintWriter&nbsp;out)</PRE>
381
<DL>
382
<DD>Transorms an xml resultset document to html and sends it to the browser<DD><DL>
383
<DT><B>Parameters:</B><DD><CODE>resultdoc</CODE> - the string representation of the document that needs
384
 to be transformed.<DD><CODE>response</CODE> - the HttpServletResponse object bound to the client.<DD><CODE>out</CODE> - the output stream to the client</DL>
385
</DD>
386
</DL>
387
<HR>
388

  
389
<A NAME="createResultDocument(java.util.Hashtable, java.lang.String)"><!-- --></A><H3>
390
createResultDocument</H3>
391
<PRE>
392
protected java.lang.String <B>createResultDocument</B>(java.util.Hashtable&nbsp;doclist,
393
                                                java.lang.String&nbsp;xmlquery)</PRE>
394
<DL>
395
<DD>Transforms a hashtable of documents to an xml or html result.
396
 If there is a returndoc, then it only displays documents of
397
 whatever type returndoc represents.  If a result is found in a document
398
 that is not of type returndoc then this attempts to find a relation 
399
 between this document and one that satifies the returndoc doctype.<DD><DL>
400
<DT><B>Parameters:</B><DD><CODE>doclist-</CODE> - the hashtable to transform<DD><CODE>xmlquery-</CODE> - the query that returned the dolist result<DD><CODE>resultdoc-</CODE> - the document type to backtrack to.</DL>
401
</DD>
402
</DL>
215 403
<!-- ========= END OF CLASS DATA ========= -->
216 404
<HR>
217 405

  
......
223 411
<A NAME="navbar_bottom_firstrow"><!-- --></A>
224 412
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">
225 413
  <TR ALIGN="center" VALIGN="top">
226
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT ID="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
414
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
227 415
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
228
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/MetaCatServlet.html"><FONT ID="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
229
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT ID="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
230
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT ID="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
231
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT ID="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
232
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT ID="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
416
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/MetaCatServlet.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
417
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
418
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
419
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
420
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
233 421
  </TR>
234 422
</TABLE>
235 423
</TD>
......
241 429
<TR>
242 430
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
243 431
&nbsp;<A HREF="../../../../edu/ucsb/nceas/metacat/ElementNode.html"><B>PREV CLASS</B></A>&nbsp;
244
&nbsp;<A HREF="../../../../edu/ucsb/nceas/metacat/MetaCatUtil.html"><B>NEXT CLASS</B></A></FONT></TD>
432
&nbsp;<A HREF="../../../../edu/ucsb/nceas/metacat/MetaCatSession.html"><B>NEXT CLASS</B></A></FONT></TD>
245 433
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
246 434
  <A HREF="../../../../index.html" TARGET="_top"><B>FRAMES</B></A>  &nbsp;
247 435
&nbsp;<A HREF="MetaCatServlet.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD>

Also available in: Unified diff