4093d8f72e6a82ebe5cf4700472ace566baf88e2
[profile/ivi/pygobject2.git] / docs / html / class-giounixoutputstream.html
1 <html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><title>gio.unix.OutputStream</title><link rel="stylesheet" href="style.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets V1.75.2"><link rel="home" href="index.html" title="PyGObject Reference Manual"><link rel="up" href="giounix-class-reference.html" title="PyGio Unix Class Reference"><link rel="prev" href="class-giounixinputstream.html" title="gio.unix.InputStream"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">gio.unix.OutputStream</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="class-giounixinputstream.html">Prev</a> </td><th width="60%" align="center">PyGio Unix Class Reference</th><td width="20%" align="right"> </td></tr></table><hr></div><div class="refentry" title="gio.unix.OutputStream"><a name="class-giounixoutputstream"></a><div class="titlepage"></div><div class="refnamediv"><h2>gio.unix.OutputStream</h2><p>gio.unix.OutputStream — Streaming output operations for UNIX file descriptors.</p></div><div class="refsect1" title="Synopsis"><a name="id3002723"></a><h2>Synopsis</h2><table bgcolor="#D0E0F0" width="100%"><tr><td><pre class="classsynopsis">class <span class="ooclass"><span class="classname">gio.unix.OutputStream</span></span>(<span class="ooclass"><span class="classname"><a class="link" href="class-giooutputstream.html" title="gio.OutputStream">gio.OutputStream</a></span></span>):
2 <code class="constructorsynopsis">    <span class="methodname"><a class="link" href="class-giounixoutputstream.html#constructor-giounixoutputstream" title="Constructor">gio.unix.OutputStream</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>fd</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>close_fd</code></strong></span></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-giounixoutputstream.html#method-giounixoutputstream--get-close-fd" title="gio.unix.OutputStream.get_close_fd">get_close_fd</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-giounixoutputstream.html#method-giounixoutputstream--get-fd" title="gio.unix.OutputStream.get_fd">get_fd</a></span>(<span class="methodparam"></span>)</code><br><code class="methodsynopsis">    def <span class="methodname"><a class="link" href="class-giounixoutputstream.html#method-giounixoutputstream--set-close-fd" title="gio.unix.OutputStream.set_close_fd">set_close_fd</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>close_fd</code></strong></span></span>)</code><br></pre></td></tr></table></div><div class="refsect1" title="Ancestry"><a name="id3051906"></a><h2>Ancestry</h2><pre class="synopsis">+-- <a class="link" href="class-gobject.html" title="gobject.GObject">gobject.GObject</a>
3   +-- <a class="link" href="class-giooutputstream.html" title="gio.OutputStream">gio.OutputStream</a>
4     +-- <a class="link" href="class-giounixoutputstream.html" title="gio.unix.OutputStream">gio.unix.OutputStream</a>
5 </pre></div><div class="refsect1" title="gio.unix.OutputStream Properties"><a name="properties-giounixoutputstream"></a><h2>gio.unix.OutputStream Properties</h2><div class="blockquote"><table width="100%" border="0" bgcolor="#E0E0E0"><tr><td valign="top"><div class="informaltable"><table width="100%" border="0"><colgroup><col width="1in"><col width="1in"><col width="4in"></colgroup><tbody><tr valign="top"><td valign="top">"close-fd"</td><td valign="top">Read - Write</td><td valign="top">Whether to close the file descriptor when the stream is closed.
6                             Default value: <code class="literal">True</code>.</td></tr><tr valign="top"><td valign="top">"fd"</td><td valign="top">Read - Write - Construct only</td><td valign="top">The file descriptor that the stream writes to. Default value: -1.</td></tr></tbody></table></div></td></tr></table></div></div><div class="refsect1" title="Description"><a name="id3009608"></a><h2>Description</h2><p>
7             <a class="link" href="class-giounixoutputstream.html" title="gio.unix.OutputStream"><code class="classname">gio.unix.OutputStream</code></a>
8             implements <a class="link" href="class-giooutputstream.html" title="gio.OutputStream"><code class="classname">gio.OutputStream</code></a>
9             for writing to a UNIX file descriptor, including asynchronous operations.
10             The file descriptor must be selectable, so it doesn't work with opened files.
11         </p><p>
12             Note that <a class="link" href="class-giounixoutputstream.html" title="gio.unix.OutputStream"><code class="classname">gio.unix.OutputStream</code></a>
13             belongs to the UNIX-specific GIO interfaces, thus you have to use the gio-unix-2.0.pc pkg-config file
14             when using it.
15         </p></div><div class="refsect1" title="Constructor"><a name="constructor-giounixoutputstream"></a><h2>Constructor</h2><pre class="programlisting"><code class="constructorsynopsis">    <span class="methodname">gio.unix.OutputStream</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>fd</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>close_fd</code></strong></span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><em class="parameter"><code>fd</code></em> :</span></p></td><td>a UNIX file descriptor.
16                 </td></tr><tr><td><p><span class="term"><em class="parameter"><code>close_fd</code></em> :</span></p></td><td><code class="literal">True</code>
17                 to close the file descriptor when done 
18                 </td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td>a new
19                 <a class="link" href="class-giounixoutputstream.html" title="gio.unix.OutputStream"><code class="classname">gio.unix.OutputStream</code></a>
20                 </td></tr></tbody></table><p>
21             Creates a new <a class="link" href="class-giounixoutputstream.html" title="gio.unix.OutputStream"><code class="classname">gio.unix.OutputStream</code></a>
22             from the given fd.
23         </p><p>
24             If close_fd is <code class="literal">True</code>, the file descriptor will be closed when the stream is closed.
25         </p></div><div class="refsect1" title="Methods"><a name="id3005969"></a><h2>Methods</h2><div class="refsect2" title="gio.unix.OutputStream.get_close_fd"><a name="method-giounixoutputstream--get-close-fd"></a><h3>gio.unix.OutputStream.get_close_fd</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_close_fd</span>(<span class="methodparam"></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td><code class="literal">True</code> if the file descriptor is closed when done.
26                     </td></tr></tbody></table><p>
27                 The <code class="methodname">get_close_fd</code>() method returns whether the file
28                 descriptor of stream will be closed when the stream is closed.
29             </p></div><div class="refsect2" title="gio.unix.OutputStream.get_fd"><a name="method-giounixoutputstream--get-fd"></a><h3>gio.unix.OutputStream.get_fd</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">get_fd</span>(<span class="methodparam"></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td>The file descriptor of stream.
30                     </td></tr></tbody></table><p>
31                 The <code class="methodname">get_fd</code>() method return the UNIX file descriptor
32                 that the stream reads from.
33             </p></div><div class="refsect2" title="gio.unix.OutputStream.set_close_fd"><a name="method-giounixoutputstream--set-close-fd"></a><h3>gio.unix.OutputStream.set_close_fd</h3><pre class="programlisting"><code class="methodsynopsis">    def <span class="methodname">set_close_fd</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>close_fd</code></strong></span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><strong class="parameter"><code>close_fd</code></strong> :</span></p></td><td><code class="literal">True</code> to close the file descriptor when done .
34                   </td></tr></tbody></table><p>
35                 The <code class="methodname">set_close_fd</code>() method sets whether the file descriptor
36                 of stream shall be closed when the stream is closed.
37             </p></div></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="class-giounixinputstream.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="giounix-class-reference.html">Up</a></td><td width="40%" align="right"> </td></tr><tr><td width="40%" align="left" valign="top">gio.unix.InputStream </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> </td></tr></table></div></body></html>