aboutsummaryrefslogtreecommitdiff
path: root/src/rps/gnunet-service-rps_sampler.h
diff options
context:
space:
mode:
authorJulius Bünger <buenger@mytum.de>2015-05-23 23:34:23 +0000
committerJulius Bünger <buenger@mytum.de>2015-05-23 23:34:23 +0000
commit2f61fb7ffc7232c69e66a13c956892d6f6d13081 (patch)
tree40d8f0f87e5a48c4dd9044d40c4479f16f428b38 /src/rps/gnunet-service-rps_sampler.h
parentc2224023ebd389a62c5a569549ee67e1f984e6ba (diff)
downloadgnunet-2f61fb7ffc7232c69e66a13c956892d6f6d13081.tar.gz
gnunet-2f61fb7ffc7232c69e66a13c956892d6f6d13081.zip
-better splitted brahms sampler and modified one
Diffstat (limited to 'src/rps/gnunet-service-rps_sampler.h')
-rw-r--r--src/rps/gnunet-service-rps_sampler.h22
1 files changed, 14 insertions, 8 deletions
diff --git a/src/rps/gnunet-service-rps_sampler.h b/src/rps/gnunet-service-rps_sampler.h
index 708de6980..3b4584d87 100644
--- a/src/rps/gnunet-service-rps_sampler.h
+++ b/src/rps/gnunet-service-rps_sampler.h
@@ -71,13 +71,7 @@ RPS_sampler_resize (struct RPS_Sampler *sampler, unsigned int new_size);
71 * Initialise a tuple of samplers. 71 * Initialise a tuple of samplers.
72 * 72 *
73 * @param init_size the size the sampler is initialised with 73 * @param init_size the size the sampler is initialised with
74 * @param id with which all newly created sampler elements are initialised 74 * @param max_round_interval maximum time a round takes
75 * @param ins_cb the callback that will be called on every PeerID that is
76 * newly inserted into a sampler element
77 * @param ins_cls the closure given to #ins_cb
78 * @param rem_cb the callback that will be called on every PeerID that is
79 * removed from a sampler element
80 * @param rem_cls the closure given to #rem_cb
81 * @return a handle to a sampler that consists of sampler elements. 75 * @return a handle to a sampler that consists of sampler elements.
82 */ 76 */
83struct RPS_Sampler * 77struct RPS_Sampler *
@@ -86,6 +80,18 @@ RPS_sampler_init (size_t init_size,
86 80
87 81
88/** 82/**
83 * Initialise a modified tuple of sampler elements.
84 *
85 * @param init_size the size the sampler is initialised with
86 * @param max_round_interval maximum time a round takes
87 * @return a handle to a sampler that consists of sampler elements.
88 */
89struct RPS_Sampler *
90RPS_sampler_mod_init (size_t init_size,
91 struct GNUNET_TIME_Relative max_round_interval);
92
93
94/**
89 * A fuction to update every sampler in the given list 95 * A fuction to update every sampler in the given list
90 * 96 *
91 * @param sampler the sampler to update. 97 * @param sampler the sampler to update.
@@ -127,7 +133,7 @@ RPS_sampler_reinitialise_by_value (struct RPS_Sampler *sampler,
127 void 133 void
128RPS_sampler_get_n_rand_peers (struct RPS_Sampler *sampler, 134RPS_sampler_get_n_rand_peers (struct RPS_Sampler *sampler,
129 RPS_sampler_n_rand_peers_ready_cb cb, 135 RPS_sampler_n_rand_peers_ready_cb cb,
130 void *cls, uint32_t num_peers, int for_client); 136 void *cls, uint32_t num_peers);
131 137
132 138
133/** 139/**