diff options
author | Christian Grothoff <christian@grothoff.org> | 2015-03-30 19:46:17 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2015-03-30 19:46:17 +0000 |
commit | bf7619be0f8e5fca7a16c28720ab908134d139bc (patch) | |
tree | 3433dea1f210b3da2329edc13183d0d8c14e0d81 /src/include/gnunet_datastore_service.h | |
parent | b47c2f2d5175300a531778727c29787ab78749b8 (diff) | |
download | gnunet-bf7619be0f8e5fca7a16c28720ab908134d139bc.tar.gz gnunet-bf7619be0f8e5fca7a16c28720ab908134d139bc.zip |
add multihashmap_clear to API
Diffstat (limited to 'src/include/gnunet_datastore_service.h')
-rw-r--r-- | src/include/gnunet_datastore_service.h | 35 |
1 files changed, 21 insertions, 14 deletions
diff --git a/src/include/gnunet_datastore_service.h b/src/include/gnunet_datastore_service.h index 39605807a..38a027200 100644 --- a/src/include/gnunet_datastore_service.h +++ b/src/include/gnunet_datastore_service.h | |||
@@ -207,7 +207,8 @@ GNUNET_DATASTORE_release_reserve (struct GNUNET_DATASTORE_Handle *h, | |||
207 | * (or rather, will already have been invoked) | 207 | * (or rather, will already have been invoked) |
208 | */ | 208 | */ |
209 | struct GNUNET_DATASTORE_QueueEntry * | 209 | struct GNUNET_DATASTORE_QueueEntry * |
210 | GNUNET_DATASTORE_update (struct GNUNET_DATASTORE_Handle *h, uint64_t uid, | 210 | GNUNET_DATASTORE_update (struct GNUNET_DATASTORE_Handle *h, |
211 | uint64_t uid, | ||
211 | uint32_t priority, | 212 | uint32_t priority, |
212 | struct GNUNET_TIME_Absolute expiration, | 213 | struct GNUNET_TIME_Absolute expiration, |
213 | unsigned int queue_priority, | 214 | unsigned int queue_priority, |
@@ -239,8 +240,10 @@ GNUNET_DATASTORE_update (struct GNUNET_DATASTORE_Handle *h, uint64_t uid, | |||
239 | */ | 240 | */ |
240 | struct GNUNET_DATASTORE_QueueEntry * | 241 | struct GNUNET_DATASTORE_QueueEntry * |
241 | GNUNET_DATASTORE_remove (struct GNUNET_DATASTORE_Handle *h, | 242 | GNUNET_DATASTORE_remove (struct GNUNET_DATASTORE_Handle *h, |
242 | const struct GNUNET_HashCode * key, size_t size, | 243 | const struct GNUNET_HashCode *key, |
243 | const void *data, unsigned int queue_priority, | 244 | size_t size, |
245 | const void *data, | ||
246 | unsigned int queue_priority, | ||
244 | unsigned int max_queue_size, | 247 | unsigned int max_queue_size, |
245 | struct GNUNET_TIME_Relative timeout, | 248 | struct GNUNET_TIME_Relative timeout, |
246 | GNUNET_DATASTORE_ContinuationWithStatus cont, | 249 | GNUNET_DATASTORE_ContinuationWithStatus cont, |
@@ -261,14 +264,16 @@ GNUNET_DATASTORE_remove (struct GNUNET_DATASTORE_Handle *h, | |||
261 | * @param uid unique identifier for the datum; | 264 | * @param uid unique identifier for the datum; |
262 | * maybe 0 if no unique identifier is available | 265 | * maybe 0 if no unique identifier is available |
263 | */ | 266 | */ |
264 | typedef void (*GNUNET_DATASTORE_DatumProcessor) (void *cls, | 267 | typedef void |
265 | const struct GNUNET_HashCode *key, | 268 | (*GNUNET_DATASTORE_DatumProcessor) (void *cls, |
266 | size_t size, const void *data, | 269 | const struct GNUNET_HashCode *key, |
267 | enum GNUNET_BLOCK_Type type, | 270 | size_t size, |
268 | uint32_t priority, | 271 | const void *data, |
269 | uint32_t anonymity, | 272 | enum GNUNET_BLOCK_Type type, |
270 | struct GNUNET_TIME_Absolute expiration, | 273 | uint32_t priority, |
271 | uint64_t uid); | 274 | uint32_t anonymity, |
275 | struct GNUNET_TIME_Absolute expiration, | ||
276 | uint64_t uid); | ||
272 | 277 | ||
273 | 278 | ||
274 | /** | 279 | /** |
@@ -293,13 +298,15 @@ typedef void (*GNUNET_DATASTORE_DatumProcessor) (void *cls, | |||
293 | * cancel | 298 | * cancel |
294 | */ | 299 | */ |
295 | struct GNUNET_DATASTORE_QueueEntry * | 300 | struct GNUNET_DATASTORE_QueueEntry * |
296 | GNUNET_DATASTORE_get_key (struct GNUNET_DATASTORE_Handle *h, uint64_t offset, | 301 | GNUNET_DATASTORE_get_key (struct GNUNET_DATASTORE_Handle *h, |
302 | uint64_t offset, | ||
297 | const struct GNUNET_HashCode *key, | 303 | const struct GNUNET_HashCode *key, |
298 | enum GNUNET_BLOCK_Type type, | 304 | enum GNUNET_BLOCK_Type type, |
299 | unsigned int queue_priority, | 305 | unsigned int queue_priority, |
300 | unsigned int max_queue_size, | 306 | unsigned int max_queue_size, |
301 | struct GNUNET_TIME_Relative timeout, | 307 | struct GNUNET_TIME_Relative timeout, |
302 | GNUNET_DATASTORE_DatumProcessor proc, void *proc_cls); | 308 | GNUNET_DATASTORE_DatumProcessor proc, |
309 | void *proc_cls); | ||
303 | 310 | ||
304 | 311 | ||
305 | /** | 312 | /** |
@@ -352,7 +359,7 @@ GNUNET_DATASTORE_get_zero_anonymity (struct GNUNET_DATASTORE_Handle *h, | |||
352 | * @param proc function to call on a random value; it | 359 | * @param proc function to call on a random value; it |
353 | * will be called once with a value (if available) | 360 | * will be called once with a value (if available) |
354 | * and always once with a value of NULL. | 361 | * and always once with a value of NULL. |
355 | * @param proc_cls closure for proc | 362 | * @param proc_cls closure for @a proc |
356 | * @return NULL if the entry was not queued, otherwise a handle that can be used to | 363 | * @return NULL if the entry was not queued, otherwise a handle that can be used to |
357 | * cancel | 364 | * cancel |
358 | */ | 365 | */ |