diff options
author | Simon McVittie <simon.mcvittie@collabora.co.uk> | 2010-07-29 15:53:33 +0100 |
---|---|---|
committer | Simon McVittie <simon.mcvittie@collabora.co.uk> | 2010-08-03 16:10:47 +0100 |
commit | a07e273d4694040ab4ed287c97bb8a99fcf46b90 (patch) | |
tree | 75d8b4d3f5b13b2556aa92932a21be239d750c80 /src/util.h | |
parent | 7cc336265aeb4423d83bb8fa7897720dfd052541 (diff) |
gabble_simple_async_countdown_new, _inc, _dec: new utility code
This encapsulates a common pattern for "plural" asynchronous operations
that are implemented as a set of parallel protocol operations: finish
only when all sub-operations have finished, with success if and
only if all sub-operations succeeded.
If this functionality proves to be useful, it should be added to
telepathy-glib, or even to GLib.
Diffstat (limited to 'src/util.h')
-rw-r--r-- | src/util.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/util.h b/src/util.h index 3d36aad26..b63da5491 100644 --- a/src/util.h +++ b/src/util.h @@ -123,4 +123,12 @@ gchar * gabble_peer_to_jid (GabbleConnection *conn, TpHandle peer, const gchar *resource); +GSimpleAsyncResult *gabble_simple_async_countdown_new (gpointer self, + GAsyncReadyCallback callback, + gpointer user_data, + gpointer source_tag, + gssize todo); +void gabble_simple_async_countdown_inc (GSimpleAsyncResult *simple); +void gabble_simple_async_countdown_dec (GSimpleAsyncResult *simple); + #endif /* __GABBLE_UTIL_H__ */ |