diff options
author | Leo Tenenbaum <pommicket@gmail.com> | 2018-08-20 21:12:06 -0400 |
---|---|---|
committer | Leo Tenenbaum <pommicket@gmail.com> | 2018-08-20 21:12:06 -0400 |
commit | 63e87c2d0c9d263f14c77b68f85c67d46ece82a9 (patch) | |
tree | 6260365cbf7d24f37d27669e8538227fcb72e243 /gtk+-mingw/share/gtk-doc/html/gio/GIOStream.html | |
parent | a4460f6d9453bbd7e584937686449cef3e19f052 (diff) |
Diffstat (limited to 'gtk+-mingw/share/gtk-doc/html/gio/GIOStream.html')
-rw-r--r-- | gtk+-mingw/share/gtk-doc/html/gio/GIOStream.html | 611 |
1 files changed, 0 insertions, 611 deletions
diff --git a/gtk+-mingw/share/gtk-doc/html/gio/GIOStream.html b/gtk+-mingw/share/gtk-doc/html/gio/GIOStream.html deleted file mode 100644 index 1356b3a..0000000 --- a/gtk+-mingw/share/gtk-doc/html/gio/GIOStream.html +++ /dev/null @@ -1,611 +0,0 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> -<html> -<head> -<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> -<title>GIOStream</title> -<meta name="generator" content="DocBook XSL Stylesheets V1.76.1"> -<link rel="home" href="index.html" title="GIO Reference Manual"> -<link rel="up" href="streaming.html" title="Streaming I/O"> -<link rel="prev" href="GOutputStream.html" title="GOutputStream"> -<link rel="next" href="GFileInputStream.html" title="GFileInputStream"> -<meta name="generator" content="GTK-Doc V1.18 (XML mode)"> -<link rel="stylesheet" href="style.css" type="text/css"> -</head> -<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"> -<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2"> -<tr valign="middle"> -<td><a accesskey="p" href="GOutputStream.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td> -<td><a accesskey="u" href="streaming.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td> -<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td> -<th width="100%" align="center">GIO Reference Manual</th> -<td><a accesskey="n" href="GFileInputStream.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td> -</tr> -<tr><td colspan="5" class="shortcuts"> -<a href="#GIOStream.synopsis" class="shortcut">Top</a> - | - <a href="#GIOStream.description" class="shortcut">Description</a> - | - <a href="#GIOStream.object-hierarchy" class="shortcut">Object Hierarchy</a> - | - <a href="#GIOStream.properties" class="shortcut">Properties</a> -</td></tr> -</table> -<div class="refentry"> -<a name="GIOStream"></a><div class="titlepage"></div> -<div class="refnamediv"><table width="100%"><tr> -<td valign="top"> -<h2><span class="refentrytitle"><a name="GIOStream.top_of_page"></a>GIOStream</span></h2> -<p>GIOStream — Base class for implementing read/write streams</p> -</td> -<td valign="top" align="right"></td> -</tr></table></div> -<div class="refsynopsisdiv"> -<a name="GIOStream.synopsis"></a><h2>Synopsis</h2> -<pre class="synopsis"> -#include <gio/gio.h> - -enum <a class="link" href="GIOStream.html#GIOStreamSpliceFlags" title="enum GIOStreamSpliceFlags">GIOStreamSpliceFlags</a>; - <a class="link" href="GIOStream.html#GIOStream-struct" title="GIOStream">GIOStream</a>; -<a class="link" href="GInputStream.html" title="GInputStream"><span class="returnvalue">GInputStream</span></a> * <a class="link" href="GIOStream.html#g-io-stream-get-input-stream" title="g_io_stream_get_input_stream ()">g_io_stream_get_input_stream</a> (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>); -<a class="link" href="GOutputStream.html" title="GOutputStream"><span class="returnvalue">GOutputStream</span></a> * <a class="link" href="GIOStream.html#g-io-stream-get-output-stream" title="g_io_stream_get_output_stream ()">g_io_stream_get_output_stream</a> (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>); -<span class="returnvalue">void</span> <a class="link" href="GIOStream.html#g-io-stream-splice-async" title="g_io_stream_splice_async ()">g_io_stream_splice_async</a> (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream1</code></em>, - <em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream2</code></em>, - <em class="parameter"><code><a class="link" href="GIOStream.html#GIOStreamSpliceFlags" title="enum GIOStreamSpliceFlags"><span class="type">GIOStreamSpliceFlags</span></a> flags</code></em>, - <em class="parameter"><code><span class="type">int</span> io_priority</code></em>, - <em class="parameter"><code><a class="link" href="GCancellable.html" title="GCancellable"><span class="type">GCancellable</span></a> *cancellable</code></em>, - <em class="parameter"><code><a class="link" href="GAsyncResult.html#GAsyncReadyCallback" title="GAsyncReadyCallback ()"><span class="type">GAsyncReadyCallback</span></a> callback</code></em>, - <em class="parameter"><code><a href="./../glib/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>); -<a href="./../glib/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="GIOStream.html#g-io-stream-splice-finish" title="g_io_stream_splice_finish ()">g_io_stream_splice_finish</a> (<em class="parameter"><code><a class="link" href="GAsyncResult.html" title="GAsyncResult"><span class="type">GAsyncResult</span></a> *result</code></em>, - <em class="parameter"><code><a href="./../glib/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>); -<a href="./../glib/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="GIOStream.html#g-io-stream-close" title="g_io_stream_close ()">g_io_stream_close</a> (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>, - <em class="parameter"><code><a class="link" href="GCancellable.html" title="GCancellable"><span class="type">GCancellable</span></a> *cancellable</code></em>, - <em class="parameter"><code><a href="./../glib/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>); -<span class="returnvalue">void</span> <a class="link" href="GIOStream.html#g-io-stream-close-async" title="g_io_stream_close_async ()">g_io_stream_close_async</a> (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>, - <em class="parameter"><code><span class="type">int</span> io_priority</code></em>, - <em class="parameter"><code><a class="link" href="GCancellable.html" title="GCancellable"><span class="type">GCancellable</span></a> *cancellable</code></em>, - <em class="parameter"><code><a class="link" href="GAsyncResult.html#GAsyncReadyCallback" title="GAsyncReadyCallback ()"><span class="type">GAsyncReadyCallback</span></a> callback</code></em>, - <em class="parameter"><code><a href="./../glib/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>); -<a href="./../glib/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="GIOStream.html#g-io-stream-close-finish" title="g_io_stream_close_finish ()">g_io_stream_close_finish</a> (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>, - <em class="parameter"><code><a class="link" href="GAsyncResult.html" title="GAsyncResult"><span class="type">GAsyncResult</span></a> *result</code></em>, - <em class="parameter"><code><a href="./../glib/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>); -<a href="./../glib/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="GIOStream.html#g-io-stream-is-closed" title="g_io_stream_is_closed ()">g_io_stream_is_closed</a> (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>); -<a href="./../glib/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="GIOStream.html#g-io-stream-has-pending" title="g_io_stream_has_pending ()">g_io_stream_has_pending</a> (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>); -<a href="./../glib/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="GIOStream.html#g-io-stream-set-pending" title="g_io_stream_set_pending ()">g_io_stream_set_pending</a> (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>, - <em class="parameter"><code><a href="./../glib/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>); -<span class="returnvalue">void</span> <a class="link" href="GIOStream.html#g-io-stream-clear-pending" title="g_io_stream_clear_pending ()">g_io_stream_clear_pending</a> (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>); -</pre> -</div> -<div class="refsect1"> -<a name="GIOStream.object-hierarchy"></a><h2>Object Hierarchy</h2> -<pre class="synopsis"> - <a href="./../gobject/gobject/gobject-The-Base-Object-Type.html#GObject">GObject</a> - +----GIOStream - +----<a class="link" href="GFileIOStream.html" title="GFileIOStream">GFileIOStream</a> - +----<a class="link" href="GSocketConnection.html" title="GSocketConnection">GSocketConnection</a> - +----<a class="link" href="GTlsConnection.html" title="GTlsConnection">GTlsConnection</a> -</pre> -</div> -<div class="refsect1"> -<a name="GIOStream.properties"></a><h2>Properties</h2> -<pre class="synopsis"> - "<a class="link" href="GIOStream.html#GIOStream--closed" title='The "closed" property'>closed</a>" <a href="./../glib/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> : Read - "<a class="link" href="GIOStream.html#GIOStream--input-stream" title='The "input-stream" property'>input-stream</a>" <a class="link" href="GInputStream.html" title="GInputStream"><span class="type">GInputStream</span></a>* : Read - "<a class="link" href="GIOStream.html#GIOStream--output-stream" title='The "output-stream" property'>output-stream</a>" <a class="link" href="GOutputStream.html" title="GOutputStream"><span class="type">GOutputStream</span></a>* : Read -</pre> -</div> -<div class="refsect1"> -<a name="GIOStream.description"></a><h2>Description</h2> -<p> -GIOStream represents an object that has both read and write streams. -Generally the two streams acts as separate input and output streams, -but they share some common resources and state. For instance, for -seekable streams they may use the same position in both streams. -</p> -<p> -Examples of <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> objects are <a class="link" href="GSocketConnection.html" title="GSocketConnection"><span class="type">GSocketConnection</span></a> which represents -a two-way network connection, and <a class="link" href="GFileIOStream.html" title="GFileIOStream"><span class="type">GFileIOStream</span></a> which represent a -file handle opened in read-write mode. -</p> -<p> -To do the actual reading and writing you need to get the substreams -with <a class="link" href="GIOStream.html#g-io-stream-get-input-stream" title="g_io_stream_get_input_stream ()"><code class="function">g_io_stream_get_input_stream()</code></a> and <a class="link" href="GIOStream.html#g-io-stream-get-output-stream" title="g_io_stream_get_output_stream ()"><code class="function">g_io_stream_get_output_stream()</code></a>. -</p> -<p> -The <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> object owns the input and the output streams, not the other -way around, so keeping the substreams alive will not keep the <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> -object alive. If the <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> object is freed it will be closed, thus -closing the substream, so even if the substreams stay alive they will -always just return a <a class="link" href="gio-GIOError.html#G-IO-ERROR-CLOSED:CAPS"><code class="literal">G_IO_ERROR_CLOSED</code></a> for all operations. -</p> -<p> -To close a stream use <a class="link" href="GIOStream.html#g-io-stream-close" title="g_io_stream_close ()"><code class="function">g_io_stream_close()</code></a> which will close the common -stream object and also the individual substreams. You can also close -the substreams themselves. In most cases this only marks the -substream as closed, so further I/O on it fails. However, some streams -may support "half-closed" states where one direction of the stream -is actually shut down. -</p> -</div> -<div class="refsect1"> -<a name="GIOStream.details"></a><h2>Details</h2> -<div class="refsect2"> -<a name="GIOStreamSpliceFlags"></a><h3>enum GIOStreamSpliceFlags</h3> -<pre class="programlisting">typedef enum { - G_IO_STREAM_SPLICE_NONE = 0, - G_IO_STREAM_SPLICE_CLOSE_STREAM1 = (1 << 0), - G_IO_STREAM_SPLICE_CLOSE_STREAM2 = (1 << 1), - G_IO_STREAM_SPLICE_WAIT_FOR_BOTH = (1 << 2) -} GIOStreamSpliceFlags; -</pre> -<p> -GIOStreamSpliceFlags determine how streams should be spliced. -</p> -<div class="variablelist"><table border="0"> -<col align="left" valign="top"> -<tbody> -<tr> -<td><p><a name="G-IO-STREAM-SPLICE-NONE:CAPS"></a><span class="term"><code class="literal">G_IO_STREAM_SPLICE_NONE</code></span></p></td> -<td>Do not close either stream. -</td> -</tr> -<tr> -<td><p><a name="G-IO-STREAM-SPLICE-CLOSE-STREAM1:CAPS"></a><span class="term"><code class="literal">G_IO_STREAM_SPLICE_CLOSE_STREAM1</code></span></p></td> -<td>Close the first stream after - the splice. -</td> -</tr> -<tr> -<td><p><a name="G-IO-STREAM-SPLICE-CLOSE-STREAM2:CAPS"></a><span class="term"><code class="literal">G_IO_STREAM_SPLICE_CLOSE_STREAM2</code></span></p></td> -<td>Close the second stream after - the splice. -</td> -</tr> -<tr> -<td><p><a name="G-IO-STREAM-SPLICE-WAIT-FOR-BOTH:CAPS"></a><span class="term"><code class="literal">G_IO_STREAM_SPLICE_WAIT_FOR_BOTH</code></span></p></td> -<td>Wait for both splice operations to finish - before calling the callback. -</td> -</tr> -</tbody> -</table></div> -<p class="since">Since 2.28</p> -</div> -<hr> -<div class="refsect2"> -<a name="GIOStream-struct"></a><h3>GIOStream</h3> -<pre class="programlisting">typedef struct _GIOStream GIOStream;</pre> -<p> -Base class for read-write streams. -</p> -</div> -<hr> -<div class="refsect2"> -<a name="g-io-stream-get-input-stream"></a><h3>g_io_stream_get_input_stream ()</h3> -<pre class="programlisting"><a class="link" href="GInputStream.html" title="GInputStream"><span class="returnvalue">GInputStream</span></a> * g_io_stream_get_input_stream (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>);</pre> -<p> -Gets the input stream for this object. This is used -for reading. -</p> -<div class="variablelist"><table border="0"> -<col align="left" valign="top"> -<tbody> -<tr> -<td><p><span class="term"><em class="parameter"><code>stream</code></em> :</span></p></td> -<td>a <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> -</td> -</tr> -<tr> -<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> -<td>a <a class="link" href="GInputStream.html" title="GInputStream"><span class="type">GInputStream</span></a>, owned by the <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a>. -Do not free. <span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span> -</td> -</tr> -</tbody> -</table></div> -<p class="since">Since 2.22</p> -</div> -<hr> -<div class="refsect2"> -<a name="g-io-stream-get-output-stream"></a><h3>g_io_stream_get_output_stream ()</h3> -<pre class="programlisting"><a class="link" href="GOutputStream.html" title="GOutputStream"><span class="returnvalue">GOutputStream</span></a> * g_io_stream_get_output_stream (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>);</pre> -<p> -Gets the output stream for this object. This is used for -writing. -</p> -<div class="variablelist"><table border="0"> -<col align="left" valign="top"> -<tbody> -<tr> -<td><p><span class="term"><em class="parameter"><code>stream</code></em> :</span></p></td> -<td>a <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> -</td> -</tr> -<tr> -<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> -<td>a <a class="link" href="GOutputStream.html" title="GOutputStream"><span class="type">GOutputStream</span></a>, owned by the <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a>. -Do not free. <span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span> -</td> -</tr> -</tbody> -</table></div> -<p class="since">Since 2.22</p> -</div> -<hr> -<div class="refsect2"> -<a name="g-io-stream-splice-async"></a><h3>g_io_stream_splice_async ()</h3> -<pre class="programlisting"><span class="returnvalue">void</span> g_io_stream_splice_async (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream1</code></em>, - <em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream2</code></em>, - <em class="parameter"><code><a class="link" href="GIOStream.html#GIOStreamSpliceFlags" title="enum GIOStreamSpliceFlags"><span class="type">GIOStreamSpliceFlags</span></a> flags</code></em>, - <em class="parameter"><code><span class="type">int</span> io_priority</code></em>, - <em class="parameter"><code><a class="link" href="GCancellable.html" title="GCancellable"><span class="type">GCancellable</span></a> *cancellable</code></em>, - <em class="parameter"><code><a class="link" href="GAsyncResult.html#GAsyncReadyCallback" title="GAsyncReadyCallback ()"><span class="type">GAsyncReadyCallback</span></a> callback</code></em>, - <em class="parameter"><code><a href="./../glib/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>);</pre> -<p> -Asyncronously splice the output stream of <em class="parameter"><code>stream1</code></em> to the input stream of -<em class="parameter"><code>stream2</code></em>, and splice the output stream of <em class="parameter"><code>stream2</code></em> to the input stream of -<em class="parameter"><code>stream1</code></em>. -</p> -<p> -When the operation is finished <em class="parameter"><code>callback</code></em> will be called. -You can then call <a class="link" href="GIOStream.html#g-io-stream-splice-finish" title="g_io_stream_splice_finish ()"><code class="function">g_io_stream_splice_finish()</code></a> to get the -result of the operation. -</p> -<div class="variablelist"><table border="0"> -<col align="left" valign="top"> -<tbody> -<tr> -<td><p><span class="term"><em class="parameter"><code>stream1</code></em> :</span></p></td> -<td>a <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a>.</td> -</tr> -<tr> -<td><p><span class="term"><em class="parameter"><code>stream2</code></em> :</span></p></td> -<td>a <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a>.</td> -</tr> -<tr> -<td><p><span class="term"><em class="parameter"><code>flags</code></em> :</span></p></td> -<td>a set of <a class="link" href="GIOStream.html#GIOStreamSpliceFlags" title="enum GIOStreamSpliceFlags"><span class="type">GIOStreamSpliceFlags</span></a>.</td> -</tr> -<tr> -<td><p><span class="term"><em class="parameter"><code>io_priority</code></em> :</span></p></td> -<td>the io priority of the request.</td> -</tr> -<tr> -<td><p><span class="term"><em class="parameter"><code>cancellable</code></em> :</span></p></td> -<td>optional <a class="link" href="GCancellable.html" title="GCancellable"><span class="type">GCancellable</span></a> object, <a href="./../glib/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to ignore. <span class="annotation">[<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span> -</td> -</tr> -<tr> -<td><p><span class="term"><em class="parameter"><code>callback</code></em> :</span></p></td> -<td>a <a class="link" href="GAsyncResult.html#GAsyncReadyCallback" title="GAsyncReadyCallback ()"><span class="type">GAsyncReadyCallback</span></a>. <span class="annotation">[<acronym title="The callback is valid until first called."><span class="acronym">scope async</span></acronym>]</span> -</td> -</tr> -<tr> -<td><p><span class="term"><em class="parameter"><code>user_data</code></em> :</span></p></td> -<td>user data passed to <em class="parameter"><code>callback</code></em>. <span class="annotation">[<acronym title="This parameter is a 'user_data', for callbacks; many bindings can pass NULL here."><span class="acronym">closure</span></acronym>]</span> -</td> -</tr> -</tbody> -</table></div> -<p class="since">Since 2.28</p> -</div> -<hr> -<div class="refsect2"> -<a name="g-io-stream-splice-finish"></a><h3>g_io_stream_splice_finish ()</h3> -<pre class="programlisting"><a href="./../glib/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> g_io_stream_splice_finish (<em class="parameter"><code><a class="link" href="GAsyncResult.html" title="GAsyncResult"><span class="type">GAsyncResult</span></a> *result</code></em>, - <em class="parameter"><code><a href="./../glib/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre> -<p> -Finishes an asynchronous io stream splice operation. -</p> -<div class="variablelist"><table border="0"> -<col align="left" valign="top"> -<tbody> -<tr> -<td><p><span class="term"><em class="parameter"><code>result</code></em> :</span></p></td> -<td>a <a class="link" href="GAsyncResult.html" title="GAsyncResult"><span class="type">GAsyncResult</span></a>.</td> -</tr> -<tr> -<td><p><span class="term"><em class="parameter"><code>error</code></em> :</span></p></td> -<td>a <a href="./../glib/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> location to store the error occurring, or <a href="./../glib/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to -ignore.</td> -</tr> -<tr> -<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> -<td> -<a href="./../glib/glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> on success, <a href="./../glib/glib/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> otherwise.</td> -</tr> -</tbody> -</table></div> -<p class="since">Since 2.28</p> -</div> -<hr> -<div class="refsect2"> -<a name="g-io-stream-close"></a><h3>g_io_stream_close ()</h3> -<pre class="programlisting"><a href="./../glib/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> g_io_stream_close (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>, - <em class="parameter"><code><a class="link" href="GCancellable.html" title="GCancellable"><span class="type">GCancellable</span></a> *cancellable</code></em>, - <em class="parameter"><code><a href="./../glib/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre> -<p> -Closes the stream, releasing resources related to it. This will also -closes the individual input and output streams, if they are not already -closed. -</p> -<p> -Once the stream is closed, all other operations will return -<a class="link" href="gio-GIOError.html#G-IO-ERROR-CLOSED:CAPS"><code class="literal">G_IO_ERROR_CLOSED</code></a>. Closing a stream multiple times will not -return an error. -</p> -<p> -Closing a stream will automatically flush any outstanding buffers -in the stream. -</p> -<p> -Streams will be automatically closed when the last reference -is dropped, but you might want to call this function to make sure -resources are released as early as possible. -</p> -<p> -Some streams might keep the backing store of the stream (e.g. a file -descriptor) open after the stream is closed. See the documentation for -the individual stream for details. -</p> -<p> -On failure the first error that happened will be reported, but the -close operation will finish as much as possible. A stream that failed -to close will still return <a class="link" href="gio-GIOError.html#G-IO-ERROR-CLOSED:CAPS"><code class="literal">G_IO_ERROR_CLOSED</code></a> for all operations. -Still, it is important to check and report the error to the user, -otherwise there might be a loss of data as all data might not be written. -</p> -<p> -If <em class="parameter"><code>cancellable</code></em> is not NULL, then the operation can be cancelled by -triggering the cancellable object from another thread. If the operation -was cancelled, the error <a class="link" href="gio-GIOError.html#G-IO-ERROR-CANCELLED:CAPS"><code class="literal">G_IO_ERROR_CANCELLED</code></a> will be returned. -Cancelling a close will still leave the stream closed, but some streams -can use a faster close that doesn't block to e.g. check errors. -</p> -<p> -The default implementation of this method just calls close on the -individual input/output streams. -</p> -<div class="variablelist"><table border="0"> -<col align="left" valign="top"> -<tbody> -<tr> -<td><p><span class="term"><em class="parameter"><code>stream</code></em> :</span></p></td> -<td>a <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> -</td> -</tr> -<tr> -<td><p><span class="term"><em class="parameter"><code>cancellable</code></em> :</span></p></td> -<td>optional <a class="link" href="GCancellable.html" title="GCancellable"><span class="type">GCancellable</span></a> object, <a href="./../glib/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to ignore. <span class="annotation">[<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span> -</td> -</tr> -<tr> -<td><p><span class="term"><em class="parameter"><code>error</code></em> :</span></p></td> -<td>location to store the error occurring, or <a href="./../glib/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to ignore</td> -</tr> -<tr> -<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> -<td> -<a href="./../glib/glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> on success, <a href="./../glib/glib/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> on failure</td> -</tr> -</tbody> -</table></div> -<p class="since">Since 2.22</p> -</div> -<hr> -<div class="refsect2"> -<a name="g-io-stream-close-async"></a><h3>g_io_stream_close_async ()</h3> -<pre class="programlisting"><span class="returnvalue">void</span> g_io_stream_close_async (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>, - <em class="parameter"><code><span class="type">int</span> io_priority</code></em>, - <em class="parameter"><code><a class="link" href="GCancellable.html" title="GCancellable"><span class="type">GCancellable</span></a> *cancellable</code></em>, - <em class="parameter"><code><a class="link" href="GAsyncResult.html#GAsyncReadyCallback" title="GAsyncReadyCallback ()"><span class="type">GAsyncReadyCallback</span></a> callback</code></em>, - <em class="parameter"><code><a href="./../glib/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>);</pre> -<p> -Requests an asynchronous close of the stream, releasing resources -related to it. When the operation is finished <em class="parameter"><code>callback</code></em> will be -called. You can then call <a class="link" href="GIOStream.html#g-io-stream-close-finish" title="g_io_stream_close_finish ()"><code class="function">g_io_stream_close_finish()</code></a> to get -the result of the operation. -</p> -<p> -For behaviour details see <a class="link" href="GIOStream.html#g-io-stream-close" title="g_io_stream_close ()"><code class="function">g_io_stream_close()</code></a>. -</p> -<p> -The asynchronous methods have a default fallback that uses threads -to implement asynchronicity, so they are optional for inheriting -classes. However, if you override one you must override all. -</p> -<div class="variablelist"><table border="0"> -<col align="left" valign="top"> -<tbody> -<tr> -<td><p><span class="term"><em class="parameter"><code>stream</code></em> :</span></p></td> -<td>a <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> -</td> -</tr> -<tr> -<td><p><span class="term"><em class="parameter"><code>io_priority</code></em> :</span></p></td> -<td>the io priority of the request</td> -</tr> -<tr> -<td><p><span class="term"><em class="parameter"><code>cancellable</code></em> :</span></p></td> -<td>optional cancellable object. <span class="annotation">[<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span> -</td> -</tr> -<tr> -<td><p><span class="term"><em class="parameter"><code>callback</code></em> :</span></p></td> -<td>callback to call when the request is satisfied. <span class="annotation">[<acronym title="The callback is valid until first called."><span class="acronym">scope async</span></acronym>]</span> -</td> -</tr> -<tr> -<td><p><span class="term"><em class="parameter"><code>user_data</code></em> :</span></p></td> -<td>the data to pass to callback function. <span class="annotation">[<acronym title="This parameter is a 'user_data', for callbacks; many bindings can pass NULL here."><span class="acronym">closure</span></acronym>]</span> -</td> -</tr> -</tbody> -</table></div> -<p class="since">Since 2.22</p> -</div> -<hr> -<div class="refsect2"> -<a name="g-io-stream-close-finish"></a><h3>g_io_stream_close_finish ()</h3> -<pre class="programlisting"><a href="./../glib/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> g_io_stream_close_finish (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>, - <em class="parameter"><code><a class="link" href="GAsyncResult.html" title="GAsyncResult"><span class="type">GAsyncResult</span></a> *result</code></em>, - <em class="parameter"><code><a href="./../glib/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre> -<p> -Closes a stream. -</p> -<div class="variablelist"><table border="0"> -<col align="left" valign="top"> -<tbody> -<tr> -<td><p><span class="term"><em class="parameter"><code>stream</code></em> :</span></p></td> -<td>a <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> -</td> -</tr> -<tr> -<td><p><span class="term"><em class="parameter"><code>result</code></em> :</span></p></td> -<td>a <a class="link" href="GAsyncResult.html" title="GAsyncResult"><span class="type">GAsyncResult</span></a> -</td> -</tr> -<tr> -<td><p><span class="term"><em class="parameter"><code>error</code></em> :</span></p></td> -<td>a <a href="./../glib/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> location to store the error occurring, or <a href="./../glib/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to -ignore</td> -</tr> -<tr> -<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> -<td> -<a href="./../glib/glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if stream was successfully closed, <a href="./../glib/glib/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> otherwise.</td> -</tr> -</tbody> -</table></div> -<p class="since">Since 2.22</p> -</div> -<hr> -<div class="refsect2"> -<a name="g-io-stream-is-closed"></a><h3>g_io_stream_is_closed ()</h3> -<pre class="programlisting"><a href="./../glib/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> g_io_stream_is_closed (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>);</pre> -<p> -Checks if a stream is closed. -</p> -<div class="variablelist"><table border="0"> -<col align="left" valign="top"> -<tbody> -<tr> -<td><p><span class="term"><em class="parameter"><code>stream</code></em> :</span></p></td> -<td>a <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> -</td> -</tr> -<tr> -<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> -<td> -<a href="./../glib/glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if the stream is closed.</td> -</tr> -</tbody> -</table></div> -<p class="since">Since 2.22</p> -</div> -<hr> -<div class="refsect2"> -<a name="g-io-stream-has-pending"></a><h3>g_io_stream_has_pending ()</h3> -<pre class="programlisting"><a href="./../glib/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> g_io_stream_has_pending (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>);</pre> -<p> -Checks if a stream has pending actions. -</p> -<div class="variablelist"><table border="0"> -<col align="left" valign="top"> -<tbody> -<tr> -<td><p><span class="term"><em class="parameter"><code>stream</code></em> :</span></p></td> -<td>a <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> -</td> -</tr> -<tr> -<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> -<td> -<a href="./../glib/glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if <em class="parameter"><code>stream</code></em> has pending actions.</td> -</tr> -</tbody> -</table></div> -<p class="since">Since 2.22</p> -</div> -<hr> -<div class="refsect2"> -<a name="g-io-stream-set-pending"></a><h3>g_io_stream_set_pending ()</h3> -<pre class="programlisting"><a href="./../glib/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> g_io_stream_set_pending (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>, - <em class="parameter"><code><a href="./../glib/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> **error</code></em>);</pre> -<p> -Sets <em class="parameter"><code>stream</code></em> to have actions pending. If the pending flag is -already set or <em class="parameter"><code>stream</code></em> is closed, it will return <a href="./../glib/glib/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> and set -<em class="parameter"><code>error</code></em>. -</p> -<div class="variablelist"><table border="0"> -<col align="left" valign="top"> -<tbody> -<tr> -<td><p><span class="term"><em class="parameter"><code>stream</code></em> :</span></p></td> -<td>a <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> -</td> -</tr> -<tr> -<td><p><span class="term"><em class="parameter"><code>error</code></em> :</span></p></td> -<td>a <a href="./../glib/glib/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> location to store the error occurring, or <a href="./../glib/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to -ignore</td> -</tr> -<tr> -<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td> -<td> -<a href="./../glib/glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if pending was previously unset and is now set.</td> -</tr> -</tbody> -</table></div> -<p class="since">Since 2.22</p> -</div> -<hr> -<div class="refsect2"> -<a name="g-io-stream-clear-pending"></a><h3>g_io_stream_clear_pending ()</h3> -<pre class="programlisting"><span class="returnvalue">void</span> g_io_stream_clear_pending (<em class="parameter"><code><a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> *stream</code></em>);</pre> -<p> -Clears the pending flag on <em class="parameter"><code>stream</code></em>. -</p> -<div class="variablelist"><table border="0"> -<col align="left" valign="top"> -<tbody><tr> -<td><p><span class="term"><em class="parameter"><code>stream</code></em> :</span></p></td> -<td>a <a class="link" href="GIOStream.html" title="GIOStream"><span class="type">GIOStream</span></a> -</td> -</tr></tbody> -</table></div> -<p class="since">Since 2.22</p> -</div> -</div> -<div class="refsect1"> -<a name="GIOStream.property-details"></a><h2>Property Details</h2> -<div class="refsect2"> -<a name="GIOStream--closed"></a><h3>The <code class="literal">"closed"</code> property</h3> -<pre class="programlisting"> "closed" <a href="./../glib/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> : Read</pre> -<p>Is the stream closed.</p> -<p>Default value: FALSE</p> -</div> -<hr> -<div class="refsect2"> -<a name="GIOStream--input-stream"></a><h3>The <code class="literal">"input-stream"</code> property</h3> -<pre class="programlisting"> "input-stream" <a class="link" href="GInputStream.html" title="GInputStream"><span class="type">GInputStream</span></a>* : Read</pre> -<p>The GInputStream to read from.</p> -</div> -<hr> -<div class="refsect2"> -<a name="GIOStream--output-stream"></a><h3>The <code class="literal">"output-stream"</code> property</h3> -<pre class="programlisting"> "output-stream" <a class="link" href="GOutputStream.html" title="GOutputStream"><span class="type">GOutputStream</span></a>* : Read</pre> -<p>The GOutputStream to write to.</p> -</div> -</div> -<div class="refsect1"> -<a name="GIOStream.see-also"></a><h2>See Also</h2> -<a class="link" href="GInputStream.html" title="GInputStream"><span class="type">GInputStream</span></a>, <a class="link" href="GOutputStream.html" title="GOutputStream"><span class="type">GOutputStream</span></a> -</div> -</div> -<div class="footer"> -<hr> - Generated by GTK-Doc V1.18</div> -</body> -</html>
\ No newline at end of file |