summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRob Bradford <rob@linux.intel.com>2010-09-02 11:14:36 +0100
committerRob Bradford <rob@linux.intel.com>2010-09-02 11:18:16 +0100
commitf1caab8c5e11963440551ab4098a933d12c21e9f (patch)
tree5aa639db4f64e4a60cf0fceaf0de6297e48066b0
parent4284ddc378fe9c6cd200b5cedb9f15b8d0e42195 (diff)
downloadlibrest-f1caab8c5e11963440551ab4098a933d12c21e9f.tar.gz
proxy-call: Add documentation for rest_proxy_call_continuous
-rw-r--r--rest/rest-proxy-call.c23
1 files changed, 23 insertions, 0 deletions
diff --git a/rest/rest-proxy-call.c b/rest/rest-proxy-call.c
index 1a9bbb9..ca90a1a 100644
--- a/rest/rest-proxy-call.c
+++ b/rest/rest-proxy-call.c
@@ -887,6 +887,29 @@ _continuous_call_message_got_chunk_cb (SoupMessage *msg,
closure->userdata);
}
+
+/**
+ * rest_proxy_call_continuous:
+ * @call: The #RestProxyCall
+ * @callback: a #RestProxyCallContinuousCallback to invoke when data is available
+ * @weak_object: The #GObject to weakly reference and tie the lifecycle to
+ * @userdata: data to pass to @callback
+ * @error: a #GError, or %NULL
+ *
+ * Asynchronously invoke @call but expect a continuous stream of content. This
+ * means that the body data will not be accumulated and thus you cannot use
+ * rest_proxy_call_get_payload()
+ *
+ * When there is data @callback will be called and when the connection is
+ * closed or the stream ends @callback will also be called.
+ *
+ * If @weak_object is disposed during the call then this call will be
+ * cancelled. If the call is cancelled then the callback will be invoked with
+ * an error state.
+ *
+ * You may unref the call after calling this function since there is an
+ * internal reference, or you may unref in the callback.
+ */
gboolean
rest_proxy_call_continuous (RestProxyCall *call,
RestProxyCallContinuousCallback callback,