summaryrefslogtreecommitdiff
path: root/docs/reference/pygio-asyncresult.xml
diff options
context:
space:
mode:
Diffstat (limited to 'docs/reference/pygio-asyncresult.xml')
-rw-r--r--docs/reference/pygio-asyncresult.xml117
1 files changed, 0 insertions, 117 deletions
diff --git a/docs/reference/pygio-asyncresult.xml b/docs/reference/pygio-asyncresult.xml
deleted file mode 100644
index abe56ce1..00000000
--- a/docs/reference/pygio-asyncresult.xml
+++ /dev/null
@@ -1,117 +0,0 @@
-<?xml version="1.0" standalone="no"?>
-<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
- "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
-
-<refentry id="class-gioasyncresult">
- <refnamediv>
- <refname>gio.AsyncResult</refname>
- <refpurpose>Asynchronous Function Results.</refpurpose>
- </refnamediv>
-
- <refsect1>
- <title>Synopsis</title>
-
- <classsynopsis language="python">
- <ooclass><classname>gio.AsyncResult</classname></ooclass>
- <ooclass><classname><link linkend="class-gobjectginterface">gobject.GInterface</link></classname></ooclass>
-
- <methodsynopsis language="python">
- <methodname><link linkend="method-gioasyncresult--get-source-object">get_source_object</link></methodname>
- <methodparam></methodparam>
- </methodsynopsis>
-
- </classsynopsis>
-
- </refsect1>
-
- <refsect1>
- <title>Ancestry</title>
-
-<synopsis>+-- <link linkend="class-gobjectginterface">gobject.GInterface</link>
- +-- <link linkend="class-gioasyncresult">gio.AsyncResult</link>
-</synopsis>
-
- </refsect1>
-
- <refsect1>
- <title>Prerequisites</title>
- <para>
- <link linkend="class-gioasyncresult"><classname>gio.AsyncResult</classname></link> is required by
- <link linkend="class-gobject"><classname>gobject.GObject</classname></link>.
- </para>
- </refsect1>
-
- <refsect1>
- <title>Known Implementation</title>
- <para>
- <link linkend="class-gioasyncresult"><classname>gio.AsyncResult</classname></link> is implemented by
- <link linkend="class-giosimpleasyncresult"><classname>gio.SimpleAsyncResult</classname></link>.
- </para>
- </refsect1>
-
- <refsect1>
- <title>Description</title>
-
- <para>
- <link linkend="class-gioasyncresult"><classname>gio.AsyncResult</classname></link>
- provides a base class for implementing asynchronous function results.
- </para>
- <para>
- Asynchronous operations are broken up into two separate operations which are chained
- together by a GAsyncReadyCallback. To begin an asynchronous operation, provide a
- GAsyncReadyCallback to the asynchronous function. This callback will be triggered when
- the operation has completed, and will be passed a GAsyncResult instance filled with the
- details of the operation's success or failure, the object the asynchronous function was
- started for and any error codes returned. The asynchronous callback function is then expected
- to call the corresponding "_finish()" function with the object the function was called for,
- and the <link linkend="class-gioasyncresult"><classname>gio.AsyncResult</classname></link>
- instance, and optionally, an error to grab any error conditions that may have occurred.
- </para>
- <para>
- The purpose of the "_finish()" function is to take the generic result of type GAsyncResult and
- return the specific result that the operation in question yields (e.g. a
- <link linkend="class-giofileenumerator"><classname>gio.FileEnumerator</classname></link>
- for a "enumerate children" operation). If the result or error status of the operation is not needed,
- there is no need to call the "_finish()" function, GIO will take care of cleaning up the result and error
- information after the GAsyncReadyCallback returns. It is also allowed to take a reference to the
- <link linkend="class-gioasyncresult"><classname>gio.AsyncResult</classname></link>
- and call "_finish()" later.
- </para>
- <para>
- The callback for an asynchronous operation is called only once, and is always called, even
- in the case of a cancelled operation. On cancellation the result is a gio.ERROR_CANCELLED error.
- </para>
- <para>
- Some ascynchronous operations are implemented using synchronous calls. These are run in a
- separate thread, if GThread has been initialized, but otherwise they are sent to the Main Event
- Loop and processed in an idle function. So, if you truly need asynchronous operations, make
- sure to initialize GThread.
- </para>
- </refsect1>
-
- <refsect1>
- <title>Methods</title>
-
- <refsect2 id="method-gioasyncresult--get-source-object">
- <title>gio.AsyncResult.get_source_object</title>
-
- <programlisting><methodsynopsis language="python">
- <methodname>get_source_object</methodname>
- <methodparam></methodparam>
- </methodsynopsis></programlisting>
-
- <variablelist>
- <varlistentry>
- <term><emphasis>Returns</emphasis>&nbsp;:</term>
- <listitem><simpara>the source object for the res.
- </simpara></listitem>
- </varlistentry>
- </variablelist>
-
- <para>
- The <methodname>get_source_object</methodname>() method gets the source object
- from a <link linkend="class-gioasyncresult"><classname>gio.AsyncResult</classname></link>
- </para>
- </refsect2>
- </refsect1>
-</refentry>