diff options
author | Christian Grothoff <christian@grothoff.org> | 2013-09-21 20:14:27 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2013-09-21 20:14:27 +0000 |
commit | 268e073a902a72ea41e7235c784d1d5d50a84436 (patch) | |
tree | b5ce6f70ed030ff723a14034055a2f258016d890 /src/include/gnunet_dht_service.h | |
parent | 21f542e9ab8c812534485e70a290991208d8b787 (diff) | |
download | gnunet-268e073a902a72ea41e7235c784d1d5d50a84436.tar.gz gnunet-268e073a902a72ea41e7235c784d1d5d50a84436.zip |
-misc doxygen fixes
Diffstat (limited to 'src/include/gnunet_dht_service.h')
-rw-r--r-- | src/include/gnunet_dht_service.h | 89 |
1 files changed, 42 insertions, 47 deletions
diff --git a/src/include/gnunet_dht_service.h b/src/include/gnunet_dht_service.h index e5c4c1ee4..1370e6bd9 100644 --- a/src/include/gnunet_dht_service.h +++ b/src/include/gnunet_dht_service.h | |||
@@ -70,21 +70,21 @@ struct GNUNET_DHT_FindPeerHandle; | |||
70 | */ | 70 | */ |
71 | enum GNUNET_DHT_RouteOption | 71 | enum GNUNET_DHT_RouteOption |
72 | { | 72 | { |
73 | /** | 73 | /** |
74 | * Default. Do nothing special. | 74 | * Default. Do nothing special. |
75 | */ | 75 | */ |
76 | GNUNET_DHT_RO_NONE = 0, | 76 | GNUNET_DHT_RO_NONE = 0, |
77 | 77 | ||
78 | /** | 78 | /** |
79 | * Each peer along the way should look at 'enc' (otherwise | 79 | * Each peer along the way should look at 'enc' (otherwise |
80 | * only the k-peers closest to the key should look at it). | 80 | * only the k-peers closest to the key should look at it). |
81 | */ | 81 | */ |
82 | GNUNET_DHT_RO_DEMULTIPLEX_EVERYWHERE = 1, | 82 | GNUNET_DHT_RO_DEMULTIPLEX_EVERYWHERE = 1, |
83 | 83 | ||
84 | /** | 84 | /** |
85 | * We should keep track of the route that the message | 85 | * We should keep track of the route that the message |
86 | * took in the P2P network. | 86 | * took in the P2P network. |
87 | */ | 87 | */ |
88 | GNUNET_DHT_RO_RECORD_ROUTE = 2, | 88 | GNUNET_DHT_RO_RECORD_ROUTE = 2, |
89 | 89 | ||
90 | /** | 90 | /** |
@@ -92,9 +92,9 @@ enum GNUNET_DHT_RouteOption | |||
92 | */ | 92 | */ |
93 | GNUNET_DHT_RO_FIND_PEER = 4, | 93 | GNUNET_DHT_RO_FIND_PEER = 4, |
94 | 94 | ||
95 | /** | 95 | /** |
96 | * Possible message option for query key randomization. | 96 | * Possible message option for query key randomization. |
97 | */ | 97 | */ |
98 | GNUNET_DHT_RO_BART = 8 | 98 | GNUNET_DHT_RO_BART = 8 |
99 | }; | 99 | }; |
100 | 100 | ||
@@ -154,19 +154,19 @@ typedef void (*GNUNET_DHT_PutContinuation)(void *cls, | |||
154 | * nearest peers this request should reach | 154 | * nearest peers this request should reach |
155 | * @param options routing options for this message | 155 | * @param options routing options for this message |
156 | * @param type type of the value | 156 | * @param type type of the value |
157 | * @param size number of bytes in data; must be less than 64k | 157 | * @param size number of bytes in @a data; must be less than 64k |
158 | * @param data the data to store | 158 | * @param data the data to store |
159 | * @param exp desired expiration time for the value | 159 | * @param exp desired expiration time for the value |
160 | * @param timeout how long to wait for transmission of this request | 160 | * @param timeout how long to wait for transmission of this request |
161 | * @param cont continuation to call when done (transmitting request to service) | 161 | * @param cont continuation to call when done (transmitting request to service) |
162 | * You must not call "GNUNET_DHT_disconnect" in this continuation | 162 | * You must not call #GNUNET_DHT_disconnect in this continuation |
163 | * @param cont_cls closure for cont | 163 | * @param cont_cls closure for @a cont |
164 | * @return handle to cancel the "PUT" operation, NULL on error | 164 | * @return handle to cancel the "PUT" operation, NULL on error |
165 | * (size too big) | 165 | * (size too big) |
166 | */ | 166 | */ |
167 | struct GNUNET_DHT_PutHandle * | 167 | struct GNUNET_DHT_PutHandle * |
168 | GNUNET_DHT_put (struct GNUNET_DHT_Handle *handle, | 168 | GNUNET_DHT_put (struct GNUNET_DHT_Handle *handle, |
169 | const struct GNUNET_HashCode * key, | 169 | const struct GNUNET_HashCode *key, |
170 | uint32_t desired_replication_level, | 170 | uint32_t desired_replication_level, |
171 | enum GNUNET_DHT_RouteOption options, | 171 | enum GNUNET_DHT_RouteOption options, |
172 | enum GNUNET_BLOCK_Type type, | 172 | enum GNUNET_BLOCK_Type type, |
@@ -183,7 +183,7 @@ GNUNET_DHT_put (struct GNUNET_DHT_Handle *handle, | |||
183 | * has not yet been sent to the service, cancelling the PUT will stop | 183 | * has not yet been sent to the service, cancelling the PUT will stop |
184 | * this from happening (but there is no way for the user of this API | 184 | * this from happening (but there is no way for the user of this API |
185 | * to tell if that is the case). The only use for this API is to | 185 | * to tell if that is the case). The only use for this API is to |
186 | * prevent a later call to 'cont' from "GNUNET_DHT_put" (i.e. because | 186 | * prevent a later call to 'cont' from #GNUNET_DHT_put (i.e. because |
187 | * the system is shutting down). | 187 | * the system is shutting down). |
188 | * | 188 | * |
189 | * @param ph put operation to cancel ('cont' will no longer be called) | 189 | * @param ph put operation to cancel ('cont' will no longer be called) |
@@ -201,29 +201,28 @@ GNUNET_DHT_put_cancel (struct GNUNET_DHT_PutHandle *ph); | |||
201 | * @param key key of the result | 201 | * @param key key of the result |
202 | * @param get_path peers on reply path (or NULL if not recorded) | 202 | * @param get_path peers on reply path (or NULL if not recorded) |
203 | * [0] = datastore's first neighbor, [length - 1] = local peer | 203 | * [0] = datastore's first neighbor, [length - 1] = local peer |
204 | * @param get_path_length number of entries in get_path | 204 | * @param get_path_length number of entries in @a get_path |
205 | * @param put_path peers on the PUT path (or NULL if not recorded) | 205 | * @param put_path peers on the PUT path (or NULL if not recorded) |
206 | * [0] = origin, [length - 1] = datastore | 206 | * [0] = origin, [length - 1] = datastore |
207 | * @param put_path_length number of entries in get_path | 207 | * @param put_path_length number of entries in @a put_path |
208 | * @param type type of the result | 208 | * @param type type of the result |
209 | * @param size number of bytes in data | 209 | * @param size number of bytes in @a data |
210 | * @param data pointer to the result data | 210 | * @param data pointer to the result data |
211 | */ | 211 | */ |
212 | typedef void (*GNUNET_DHT_GetIterator) (void *cls, | 212 | typedef void (*GNUNET_DHT_GetIterator) (void *cls, |
213 | struct GNUNET_TIME_Absolute exp, | 213 | struct GNUNET_TIME_Absolute exp, |
214 | const struct GNUNET_HashCode * key, | 214 | const struct GNUNET_HashCode *key, |
215 | const struct GNUNET_PeerIdentity * | 215 | const struct GNUNET_PeerIdentity *get_path, |
216 | get_path, unsigned int get_path_length, | 216 | unsigned int get_path_length, |
217 | const struct GNUNET_PeerIdentity * | 217 | const struct GNUNET_PeerIdentity *put_path, |
218 | put_path, unsigned int put_path_length, | 218 | unsigned int put_path_length, |
219 | enum GNUNET_BLOCK_Type type, | 219 | enum GNUNET_BLOCK_Type type, |
220 | size_t size, const void *data); | 220 | size_t size, const void *data); |
221 | 221 | ||
222 | 222 | ||
223 | |||
224 | /** | 223 | /** |
225 | * Perform an asynchronous GET operation on the DHT identified. See | 224 | * Perform an asynchronous GET operation on the DHT identified. See |
226 | * also "GNUNET_BLOCK_evaluate". | 225 | * also #GNUNET_BLOCK_evaluate. |
227 | * | 226 | * |
228 | * @param handle handle to the DHT service | 227 | * @param handle handle to the DHT service |
229 | * @param type expected type of the response object | 228 | * @param type expected type of the response object |
@@ -232,9 +231,9 @@ typedef void (*GNUNET_DHT_GetIterator) (void *cls, | |||
232 | nearest peers this request should reach | 231 | nearest peers this request should reach |
233 | * @param options routing options for this message | 232 | * @param options routing options for this message |
234 | * @param xquery extended query data (can be NULL, depending on type) | 233 | * @param xquery extended query data (can be NULL, depending on type) |
235 | * @param xquery_size number of bytes in xquery | 234 | * @param xquery_size number of bytes in @a xquery |
236 | * @param iter function to call on each result | 235 | * @param iter function to call on each result |
237 | * @param iter_cls closure for iter | 236 | * @param iter_cls closure for @a iter |
238 | * | 237 | * |
239 | * @return handle to stop the async get | 238 | * @return handle to stop the async get |
240 | */ | 239 | */ |
@@ -254,7 +253,7 @@ GNUNET_DHT_get_start (struct GNUNET_DHT_Handle *handle, | |||
254 | * | 253 | * |
255 | * @param get_handle get operation for which results should be filtered | 254 | * @param get_handle get operation for which results should be filtered |
256 | * @param num_results number of results to be blocked that are | 255 | * @param num_results number of results to be blocked that are |
257 | * provided in this call (size of the 'results' array) | 256 | * provided in this call (size of the @a results array) |
258 | * @param results array of hash codes over the 'data' of the results | 257 | * @param results array of hash codes over the 'data' of the results |
259 | * to be blocked | 258 | * to be blocked |
260 | */ | 259 | */ |
@@ -289,7 +288,7 @@ struct GNUNET_DHT_MonitorHandle; | |||
289 | * @param options Options, for instance RecordRoute, DemultiplexEverywhere. | 288 | * @param options Options, for instance RecordRoute, DemultiplexEverywhere. |
290 | * @param type The type of data in the request. | 289 | * @param type The type of data in the request. |
291 | * @param hop_count Hop count so far. | 290 | * @param hop_count Hop count so far. |
292 | * @param path_length number of entries in path (or 0 if not recorded). | 291 | * @param path_length number of entries in @a path (or 0 if not recorded). |
293 | * @param path peers on the GET path (or NULL if not recorded). | 292 | * @param path peers on the GET path (or NULL if not recorded). |
294 | * @param desired_replication_level Desired replication level. | 293 | * @param desired_replication_level Desired replication level. |
295 | * @param key Key of the requested data. | 294 | * @param key Key of the requested data. |
@@ -309,24 +308,22 @@ typedef void (*GNUNET_DHT_MonitorGetCB) (void *cls, | |||
309 | * @param cls Closure. | 308 | * @param cls Closure. |
310 | * @param type The type of data in the result. | 309 | * @param type The type of data in the result. |
311 | * @param get_path Peers on GET path (or NULL if not recorded). | 310 | * @param get_path Peers on GET path (or NULL if not recorded). |
312 | * @param get_path_length number of entries in get_path. | 311 | * @param get_path_length number of entries in @a get_path. |
313 | * @param put_path peers on the PUT path (or NULL if not recorded). | 312 | * @param put_path peers on the PUT path (or NULL if not recorded). |
314 | * @param put_path_length number of entries in get_path. | 313 | * @param put_path_length number of entries in @a get_path. |
315 | * @param exp Expiration time of the data. | 314 | * @param exp Expiration time of the data. |
316 | * @param key Key of the data. | 315 | * @param key Key of the data. |
317 | * @param data Pointer to the result data. | 316 | * @param data Pointer to the result data. |
318 | * @param size Number of bytes in data. | 317 | * @param size Number of bytes in @a data. |
319 | */ | 318 | */ |
320 | typedef void (*GNUNET_DHT_MonitorGetRespCB) (void *cls, | 319 | typedef void (*GNUNET_DHT_MonitorGetRespCB) (void *cls, |
321 | enum GNUNET_BLOCK_Type type, | 320 | enum GNUNET_BLOCK_Type type, |
322 | const struct GNUNET_PeerIdentity | 321 | const struct GNUNET_PeerIdentity *get_path, |
323 | *get_path, | ||
324 | unsigned int get_path_length, | 322 | unsigned int get_path_length, |
325 | const struct GNUNET_PeerIdentity | 323 | const struct GNUNET_PeerIdentity *put_path, |
326 | * put_path, | ||
327 | unsigned int put_path_length, | 324 | unsigned int put_path_length, |
328 | struct GNUNET_TIME_Absolute exp, | 325 | struct GNUNET_TIME_Absolute exp, |
329 | const struct GNUNET_HashCode * key, | 326 | const struct GNUNET_HashCode *key, |
330 | const void *data, | 327 | const void *data, |
331 | size_t size); | 328 | size_t size); |
332 | 329 | ||
@@ -337,7 +334,7 @@ typedef void (*GNUNET_DHT_MonitorGetRespCB) (void *cls, | |||
337 | * @param options Options, for instance RecordRoute, DemultiplexEverywhere. | 334 | * @param options Options, for instance RecordRoute, DemultiplexEverywhere. |
338 | * @param type The type of data in the request. | 335 | * @param type The type of data in the request. |
339 | * @param hop_count Hop count so far. | 336 | * @param hop_count Hop count so far. |
340 | * @param path_length number of entries in path (or 0 if not recorded). | 337 | * @param path_length number of entries in @a path (or 0 if not recorded). |
341 | * @param path peers on the PUT path (or NULL if not recorded). | 338 | * @param path peers on the PUT path (or NULL if not recorded). |
342 | * @param desired_replication_level Desired replication level. | 339 | * @param desired_replication_level Desired replication level. |
343 | * @param exp Expiration time of the data. | 340 | * @param exp Expiration time of the data. |
@@ -353,7 +350,7 @@ typedef void (*GNUNET_DHT_MonitorPutCB) (void *cls, | |||
353 | unsigned int path_length, | 350 | unsigned int path_length, |
354 | const struct GNUNET_PeerIdentity *path, | 351 | const struct GNUNET_PeerIdentity *path, |
355 | struct GNUNET_TIME_Absolute exp, | 352 | struct GNUNET_TIME_Absolute exp, |
356 | const struct GNUNET_HashCode * key, | 353 | const struct GNUNET_HashCode *key, |
357 | const void *data, | 354 | const void *data, |
358 | size_t size); | 355 | size_t size); |
359 | 356 | ||
@@ -366,8 +363,7 @@ typedef void (*GNUNET_DHT_MonitorPutCB) (void *cls, | |||
366 | * @param get_cb Callback to process monitored get messages. | 363 | * @param get_cb Callback to process monitored get messages. |
367 | * @param get_resp_cb Callback to process monitored get response messages. | 364 | * @param get_resp_cb Callback to process monitored get response messages. |
368 | * @param put_cb Callback to process monitored put messages. | 365 | * @param put_cb Callback to process monitored put messages. |
369 | * @param cb_cls Closure for cb. | 366 | * @param cb_cls Closure for callbacks |
370 | * | ||
371 | * @return Handle to stop monitoring. | 367 | * @return Handle to stop monitoring. |
372 | */ | 368 | */ |
373 | struct GNUNET_DHT_MonitorHandle * | 369 | struct GNUNET_DHT_MonitorHandle * |
@@ -382,10 +378,9 @@ GNUNET_DHT_monitor_start (struct GNUNET_DHT_Handle *handle, | |||
382 | 378 | ||
383 | /** | 379 | /** |
384 | * Stop monitoring. | 380 | * Stop monitoring. |
381 | * On return handle will no longer be valid, caller must not use again!!! | ||
385 | * | 382 | * |
386 | * @param handle The handle to the monitor request returned by monitor_start. | 383 | * @param handle The handle to the monitor request returned by monitor_start. |
387 | * | ||
388 | * On return handle will no longer be valid, caller must not use again!!! | ||
389 | */ | 384 | */ |
390 | void | 385 | void |
391 | GNUNET_DHT_monitor_stop (struct GNUNET_DHT_MonitorHandle *handle); | 386 | GNUNET_DHT_monitor_stop (struct GNUNET_DHT_MonitorHandle *handle); |