rtt-f030/components/net/uip/doc/html/a00110.html

108 lines
10 KiB
HTML
Raw Normal View History

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>uIP 1.0: apps/webclient/webclient.c File Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.4.6 -->
<div class="tabs">
<ul>
<li><a href="main.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="modules.html"><span>Modules</span></a></li>
<li><a href="classes.html"><span>Data&nbsp;Structures</span></a></li>
<li id="current"><a href="files.html"><span>Files</span></a></li>
<li><a href="examples.html"><span>Examples</span></a></li>
</ul></div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul></div>
<h1>apps/webclient/webclient.c File Reference</h1><hr><a name="_details"></a><h2>Detailed Description</h2>
Implementation of the HTTP client.
<p>
<dl compact><dt><b>Author:</b></dt><dd>Adam Dunkels &lt;<a href="mailto:adam@dunkels.com">adam@dunkels.com</a>&gt; </dd></dl>
<p>
Definition in file <a class="el" href="a00180.html">webclient.c</a>.
<p>
<code>#include &quot;<a class="el" href="a00202.html">uip.h</a>&quot;</code><br>
<code>#include &quot;uiplib.h&quot;</code><br>
<code>#include &quot;<a class="el" href="a00181.html">webclient.h</a>&quot;</code><br>
<code>#include &quot;<a class="el" href="a00173.html">resolv.h</a>&quot;</code><br>
<code>#include &lt;string.h&gt;</code><br>
<p>
<a href="a00180.html">Go to the source code of this file.</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Defines</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="g31be289fd8ec3fe09b0088165d13976d"></a><!-- doxytag: member="webclient.c::WEBCLIENT_TIMEOUT" ref="g31be289fd8ec3fe09b0088165d13976d" args="" -->
#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#g31be289fd8ec3fe09b0088165d13976d">WEBCLIENT_TIMEOUT</a>&nbsp;&nbsp;&nbsp;100</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="g8714af98a550f10dc814db92b08d1b0d"></a><!-- doxytag: member="webclient.c::WEBCLIENT_STATE_STATUSLINE" ref="g8714af98a550f10dc814db92b08d1b0d" args="" -->
#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#g8714af98a550f10dc814db92b08d1b0d">WEBCLIENT_STATE_STATUSLINE</a>&nbsp;&nbsp;&nbsp;0</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="gc4357cec23abca29d2bb885803625a6a"></a><!-- doxytag: member="webclient.c::WEBCLIENT_STATE_HEADERS" ref="gc4357cec23abca29d2bb885803625a6a" args="" -->
#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#gc4357cec23abca29d2bb885803625a6a">WEBCLIENT_STATE_HEADERS</a>&nbsp;&nbsp;&nbsp;1</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="g4d457c50e6f2cef57167c3804ce8bf7c"></a><!-- doxytag: member="webclient.c::WEBCLIENT_STATE_DATA" ref="g4d457c50e6f2cef57167c3804ce8bf7c" args="" -->
#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#g4d457c50e6f2cef57167c3804ce8bf7c">WEBCLIENT_STATE_DATA</a>&nbsp;&nbsp;&nbsp;2</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="g863c94b0ed4a76997e53a3ccd5d0b6c3"></a><!-- doxytag: member="webclient.c::WEBCLIENT_STATE_CLOSE" ref="g863c94b0ed4a76997e53a3ccd5d0b6c3" args="" -->
#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#g863c94b0ed4a76997e53a3ccd5d0b6c3">WEBCLIENT_STATE_CLOSE</a>&nbsp;&nbsp;&nbsp;3</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="g40fb1fb2d990ce04ae9bbee275627c03"></a><!-- doxytag: member="webclient.c::HTTPFLAG_NONE" ref="g40fb1fb2d990ce04ae9bbee275627c03" args="" -->
#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#g40fb1fb2d990ce04ae9bbee275627c03">HTTPFLAG_NONE</a>&nbsp;&nbsp;&nbsp;0</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="gda99954e0f6905091885934e86c278cc"></a><!-- doxytag: member="webclient.c::HTTPFLAG_OK" ref="gda99954e0f6905091885934e86c278cc" args="" -->
#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#gda99954e0f6905091885934e86c278cc">HTTPFLAG_OK</a>&nbsp;&nbsp;&nbsp;1</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="gd895686859ae7d178d31be04eb0a1a97"></a><!-- doxytag: member="webclient.c::HTTPFLAG_MOVED" ref="gd895686859ae7d178d31be04eb0a1a97" args="" -->
#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#gd895686859ae7d178d31be04eb0a1a97">HTTPFLAG_MOVED</a>&nbsp;&nbsp;&nbsp;2</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="g38af81a4c9884ce89803fc3e52383112"></a><!-- doxytag: member="webclient.c::HTTPFLAG_ERROR" ref="g38af81a4c9884ce89803fc3e52383112" args="" -->
#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#g38af81a4c9884ce89803fc3e52383112">HTTPFLAG_ERROR</a>&nbsp;&nbsp;&nbsp;3</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="g3212e70c55244608ac16316888c354f0"></a><!-- doxytag: member="webclient.c::ISO_nl" ref="g3212e70c55244608ac16316888c354f0" args="" -->
#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#g3212e70c55244608ac16316888c354f0">ISO_nl</a>&nbsp;&nbsp;&nbsp;0x0a</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="g6cda47c85ce1b58b501b44ac9cccc50e"></a><!-- doxytag: member="webclient.c::ISO_cr" ref="g6cda47c85ce1b58b501b44ac9cccc50e" args="" -->
#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#g6cda47c85ce1b58b501b44ac9cccc50e">ISO_cr</a>&nbsp;&nbsp;&nbsp;0x0d</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="g71e1b022f7b7fa3a154f19372b239935"></a><!-- doxytag: member="webclient.c::ISO_space" ref="g71e1b022f7b7fa3a154f19372b239935" args="" -->
#define&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#g71e1b022f7b7fa3a154f19372b239935">ISO_space</a>&nbsp;&nbsp;&nbsp;0x20</td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#g4433d3af16ea083a81576d0f18ba57c9">webclient_mimetype</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Obtain the MIME type of the current HTTP data stream. <a href="a00163.html#g4433d3af16ea083a81576d0f18ba57c9"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#g41e616d3fcc17e0aabfe8ab45ef0d30f">webclient_filename</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Obtain the filename of the current HTTP data stream. <a href="a00163.html#g41e616d3fcc17e0aabfe8ab45ef0d30f"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">char *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#g0e0ea5f24b77f124ba33bcbc7ede5bfb">webclient_hostname</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Obtain the hostname of the current HTTP data stream. <a href="a00163.html#g0e0ea5f24b77f124ba33bcbc7ede5bfb"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">unsigned short&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#g2a939aa4fcffabbce1dc1f784a7e0ad3">webclient_port</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Obtain the port number of the current HTTP data stream. <a href="a00163.html#g2a939aa4fcffabbce1dc1f784a7e0ad3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="g3caacabb2fe1c71921e1a471719ccbd2"></a><!-- doxytag: member="webclient.c::webclient_init" ref="g3caacabb2fe1c71921e1a471719ccbd2" args="(void)" -->
void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#g3caacabb2fe1c71921e1a471719ccbd2">webclient_init</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Initialize the webclient module. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="g1d34be506a61db90dd7829117efdf8cf"></a><!-- doxytag: member="webclient.c::webclient_close" ref="g1d34be506a61db90dd7829117efdf8cf" args="(void)" -->
void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#g1d34be506a61db90dd7829117efdf8cf">webclient_close</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Close the currently open HTTP connection. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">unsigned char&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#gf9385ef9ecc74c7d53ff2f15e62bfde3">webclient_get</a> (char *host, <a class="el" href="a00153.html#g77570ac4fcab86864fa1916e55676da2">u16_t</a> port, char *file)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Open an HTTP connection to a web server and ask for a file using the GET method. <a href="a00163.html#gf9385ef9ecc74c7d53ff2f15e62bfde3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="g9e6d2864f390a4ba1ac60dc65e2b9815"></a><!-- doxytag: member="webclient.c::webclient_appcall" ref="g9e6d2864f390a4ba1ac60dc65e2b9815" args="(void)" -->
void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00163.html#g9e6d2864f390a4ba1ac60dc65e2b9815">webclient_appcall</a> (void)</td></tr>
</table>
<hr size="1"><address style="align: right;"><small>Generated on Mon Jun 12 10:23:01 2006 for uIP 1.0 by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.4.6 </small></address>
</body>
</html>