Initial commit
[yaz4j-moved-to-github.git] / dependencies / yaz-2.1.28 / doc / soap.http.html
1 <html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>2. HTTP</title><meta name="generator" content="DocBook XSL Stylesheets V1.70.1"><link rel="start" href="index.html" title="YAZ User's Guide and Reference"><link rel="up" href="soap.html" title="Chapter 7. SOAP and SRU"><link rel="prev" href="soap.html" title="Chapter 7. SOAP and SRU"><link rel="next" href="soap.xml.html" title="3. SOAP Packages"></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">2. HTTP</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="soap.html">Prev</a> </td><th width="60%" align="center">Chapter 7. SOAP and SRU</th><td width="20%" align="right"> <a accesskey="n" href="soap.xml.html">Next</a></td></tr></table><hr></div><div class="sect1" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="soap.http"></a>2. HTTP</h2></div></div></div><p>
2       YAZ only offers HTTP as transport carrier for SOAP, but it is
3       relatively easy to change that.
4     </p><p>
5       The following definition of <code class="literal">Z_GDU</code> (Generic Data
6       Unit) allows for both HTTP and Z39.50 in one packet.
7     </p><pre class="synopsis">
8 #include &lt;yaz/zgdu.h&gt;
9
10 #define Z_GDU_Z3950         1
11 #define Z_GDU_HTTP_Request  2
12 #define Z_GDU_HTTP_Response 3
13 typedef struct {
14   int which;
15   union {
16     Z_APDU *z3950;
17     Z_HTTP_Request *HTTP_Request;
18     Z_HTTP_Response *HTTP_Response;
19   } u;
20 } Z_GDU ;
21     </pre><p>
22       The corresponding Z_GDU encoder/decoder is <code class="function">z_GDU</code>.
23       The <code class="literal">z3950</code> is any of the known BER encoded Z39.50
24       APDUs.
25       <code class="literal">HTTP_Request</code> and <code class="literal">HTTP_Response</code>
26       is the HTTP Request and Response respectively.
27     </p></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="soap.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="soap.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="soap.xml.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Chapter 7. SOAP and SRU </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> 3. SOAP Packages</td></tr></table></div></body></html>