reference/gearman/gearmanclient/setcompletecallback.xml
3c0b61c45a5dabe46865510311e57b77ea3dddb7
...
...
@@ -1,6 +1,5 @@
1
1
<?xml version="1.0" encoding="utf-8"?>
2
2
<!-- $Revision$ -->
3
-

4
3
<refentry xml:id="gearmanclient.setcompletecallback" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
5
4
<refnamediv>
6
5
<refname>GearmanClient::setCompleteCallback</refname>
...
...
@@ -9,13 +8,18 @@
9
8

10
9
<refsect1 role="description">
11
10
&reftitle.description;
12
-
<methodsynopsis>
11
+
<methodsynopsis role="GearmanClient">
13
12
<modifier>public</modifier> <type>bool</type><methodname>GearmanClient::setCompleteCallback</methodname>
14
-
<methodparam><type>callable</type><parameter>callback</parameter></methodparam>
13
+
<methodparam><type>callable</type><parameter>function</parameter></methodparam>
15
14
</methodsynopsis>
16
15
<para>
17
-
Use to set a function to be called when a task is completed. The callback function should
18
-
accept a single argument, a <classname>GearmanTask</classname> object.
16
+
Use to set a function to be called when a <classname>GearmanTask</classname> is completed, or
17
+
when <methodname>GearmanJob::sendComplete</methodname> is invoked by a worker (whichever happens
18
+
first).
19
+
</para>
20
+
<para>
21
+
This callback executes only when executing a <classname>GearmanTask</classname> using
22
+
<methodname>GearmanClient::runTasks</methodname>. It is not used for individual jobs.
19
23
</para>
20
24
</refsect1>
21
25

...
...
@@ -24,7 +28,7 @@
24
28
<para>
25
29
<variablelist>
26
30
<varlistentry>
27
-
<term><parameter>callback</parameter></term>
31
+
<term><parameter>function</parameter></term>
28
32
<listitem>
29
33
<para>
30
34
A function to be called
...
...
@@ -58,7 +62,6 @@
58
62
</refsect1>
59
63

60
64
</refentry>
61
-

62
65
<!-- Keep this comment at the end of the file
63
66
Local variables:
64
67
mode: sgml
65
68