You should have received a copy of the GNU General Public License
along with GNUnet; see the file COPYING. If not, write to the
- Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- Boston, MA 02111-1307, USA.
+ Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ Boston, MA 02110-1301, USA.
*/
/**
*/
struct RPS_Sampler;
+/**
+ * A handle to cancel a request.
+ */
+struct RPS_SamplerRequestHandle;
+
/**
* Callback that is called from _get_n_rand_peers() when the PeerIDs are ready.
* #GNUNET_NO if used internally
* @param num_peers the number of peers requested
*/
- void
+struct RPS_SamplerRequestHandle *
RPS_sampler_get_n_rand_peers (struct RPS_Sampler *sampler,
RPS_sampler_n_rand_peers_ready_cb cb,
void *cls, uint32_t num_peers);
+/**
+ * Cancle a request issued through #RPS_sampler_n_rand_peers_ready_cb.
+ *
+ * @param req_handle the handle to the request
+ */
+void
+RPS_sampler_request_cancel (struct RPS_SamplerRequestHandle *req_handle);
+
/**
* Counts how many Samplers currently hold a given PeerID.