aboutsummaryrefslogtreecommitdiff
path: root/src/rps/gnunet-service-rps_sampler.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/rps/gnunet-service-rps_sampler.h')
-rw-r--r--src/rps/gnunet-service-rps_sampler.h15
1 files changed, 14 insertions, 1 deletions
diff --git a/src/rps/gnunet-service-rps_sampler.h b/src/rps/gnunet-service-rps_sampler.h
index 83705b013..f33e7430c 100644
--- a/src/rps/gnunet-service-rps_sampler.h
+++ b/src/rps/gnunet-service-rps_sampler.h
@@ -34,6 +34,11 @@
34 */ 34 */
35struct RPS_Sampler; 35struct RPS_Sampler;
36 36
37/**
38 * A handle to cancel a request.
39 */
40struct RPS_SamplerRequestHandle;
41
37 42
38/** 43/**
39 * Callback that is called from _get_n_rand_peers() when the PeerIDs are ready. 44 * Callback that is called from _get_n_rand_peers() when the PeerIDs are ready.
@@ -130,11 +135,19 @@ RPS_sampler_reinitialise_by_value (struct RPS_Sampler *sampler,
130 * #GNUNET_NO if used internally 135 * #GNUNET_NO if used internally
131 * @param num_peers the number of peers requested 136 * @param num_peers the number of peers requested
132 */ 137 */
133 void 138struct RPS_SamplerRequestHandle *
134RPS_sampler_get_n_rand_peers (struct RPS_Sampler *sampler, 139RPS_sampler_get_n_rand_peers (struct RPS_Sampler *sampler,
135 RPS_sampler_n_rand_peers_ready_cb cb, 140 RPS_sampler_n_rand_peers_ready_cb cb,
136 void *cls, uint32_t num_peers); 141 void *cls, uint32_t num_peers);
137 142
143/**
144 * Cancle a request issued through #RPS_sampler_n_rand_peers_ready_cb.
145 *
146 * @param req_handle the handle to the request
147 */
148void
149RPS_sampler_request_cancel (struct RPS_SamplerRequestHandle *req_handle);
150
138 151
139/** 152/**
140 * Counts how many Samplers currently hold a given PeerID. 153 * Counts how many Samplers currently hold a given PeerID.