<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"> <title>sc68fordevelopers: /home/mandrake/rpm/BUILD/sc68-2.2.1/file68/istream68_fd.h File Reference</title> <link href="tabs.css" rel="stylesheet" type="text/css"> <link href="doxygen.css" rel="stylesheet" type="text/css"> </head><body> <!-- Generated by Doxygen 1.5.9 --> <div class="navigation" id="top"> <div class="tabs"> <ul> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="modules.html"><span>Modules</span></a></li> <li><a href="annotated.html"><span>Data Structures</span></a></li> <li class="current"><a href="files.html"><span>Files</span></a></li> </ul> </div> <div class="tabs"> <ul> <li><a href="files.html"><span>File List</span></a></li> <li><a href="globals.html"><span>Globals</span></a></li> </ul> </div> </div> <div class="contents"> <h1>/home/mandrake/rpm/BUILD/sc68-2.2.1/file68/istream68_fd.h File Reference</h1>file descriptor stream operation. <a href="#_details">More...</a> <p> <code>#include "<a class="el" href="istream68_8h_source.html">file68/istream68.h</a>"</code><br> <p> <a href="istream68__fd_8h_source.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>Functions</h2></td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="struct__istream__t.html">istream_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="istream68__fd_8h.html#801e37bd04c5c29f551488fb1e285601">istream_fd_create</a> (const char *fname, int fd, int mode)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Creates a stream for "UNIX" file descriptor. <a href="#801e37bd04c5c29f551488fb1e285601"></a><br></td></tr> </table> <hr><h2>Detailed Description</h2> file descriptor stream operation. <p> <dl class="author" compact><dt><b>Author:</b></dt><dd>benjamin gerard </dd></dl> <dl class="date" compact><dt><b>Date:</b></dt><dd>2003/08/08 </dd></dl> <dl class="rcs" compact><dt><b>Id</b></dt><dd><a class="el" href="istream68__fd_8h.html" title="file descriptor stream operation.">istream68_fd.h</a>,v 1.2 2003/09/30 06:29:57 benjihan Exp </dd></dl> <p> isteam68_fd implements istream_t for file descriptor. <hr><h2>Function Documentation</h2> <a class="anchor" name="801e37bd04c5c29f551488fb1e285601"></a><!-- doxytag: member="istream68_fd.h::istream_fd_create" ref="801e37bd04c5c29f551488fb1e285601" args="(const char *fname, int fd, int mode)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="struct__istream__t.html">istream_t</a>* istream_fd_create </td> <td>(</td> <td class="paramtype">const char * </td> <td class="paramname"> <em>fname</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">int </td> <td class="paramname"> <em>fd</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">int </td> <td class="paramname"> <em>mode</em></td><td> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td><td></td> </tr> </table> </div> <div class="memdoc"> <p> Creates a stream for "UNIX" file descriptor. <p> If fd parameters is not -1, it is used to as file descriptor for the stream and fname is used for naming the stream. Else the file is open as a regular file with fname as path.<p> <dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>fname</em> </td><td>path of file or 0. </td></tr> <tr><td valign="top"></td><td valign="top"><em>fd</em> </td><td>file decriptor or -1. </td></tr> <tr><td valign="top"></td><td valign="top"><em>mode</em> </td><td>bit-0: read access, bit-1: write access.</td></tr> </table> </dl> <dl class="return" compact><dt><b>Returns:</b></dt><dd>stream </dd></dl> <dl compact><dt><b>Return values:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>0</em> </td><td>on error</td></tr> </table> </dl> <dl class="note" compact><dt><b>Note:</b></dt><dd>filename is internally copied. <p> Even if fd is given the <a class="el" href="istream68_8h.html#07586f012244d8116a2915a1a4f31daa" title="Open stream.">istream_open()</a> must be call. </dd></dl> <dl class="warning" compact><dt><b>Warning:</b></dt><dd>When opening a stream with an already opened descriptor the mode should match the real open mode but since no tests are performed before calling r/w access, it should not failed in case of wrong access on given mode. </dd></dl> </div> </div><p> </div> <hr size="1"><address style="text-align: right;"><small>Generated on Tue Sep 15 03:58:05 2009 for sc68fordevelopers by <a href="http://www.doxygen.org/index.html"> <img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.9 </small></address> </body> </html>