aboutsummaryrefslogtreecommitdiff
path: root/src/include/gnunet_identity_service.h
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2013-08-24 15:54:21 +0000
committerChristian Grothoff <christian@grothoff.org>2013-08-24 15:54:21 +0000
commit0baf38e846d5a4cd5b5b4c2ec900762fceb87712 (patch)
tree0f54a86cd481c2ea93aea18e217b71a6a578114c /src/include/gnunet_identity_service.h
parent5d8db7e97036433978f995389eac3997dae282e1 (diff)
downloadgnunet-0baf38e846d5a4cd5b5b4c2ec900762fceb87712.tar.gz
gnunet-0baf38e846d5a4cd5b5b4c2ec900762fceb87712.zip
-more convenient API to lookup egos
Diffstat (limited to 'src/include/gnunet_identity_service.h')
-rw-r--r--src/include/gnunet_identity_service.h42
1 files changed, 42 insertions, 0 deletions
diff --git a/src/include/gnunet_identity_service.h b/src/include/gnunet_identity_service.h
index 1d682cb1e..a31c063d0 100644
--- a/src/include/gnunet_identity_service.h
+++ b/src/include/gnunet_identity_service.h
@@ -272,6 +272,48 @@ void
272GNUNET_IDENTITY_cancel (struct GNUNET_IDENTITY_Operation *op); 272GNUNET_IDENTITY_cancel (struct GNUNET_IDENTITY_Operation *op);
273 273
274 274
275/* ************* convenience API to lookup an ego ***************** */
276
277/**
278 * Function called with the result.
279 *
280 * @param cls closure
281 * @param ego NULL on error / ego not found
282 */
283typedef void (*GNUNET_IDENTITY_EgoCallback)(void *cls,
284 const struct GNUNET_IDENTITY_Ego *ego);
285
286/**
287 * Handle for ego lookup.
288 */
289struct GNUNET_IDENTITY_EgoLookup;
290
291
292/**
293 * Lookup an ego by name.
294 *
295 * @param cfg configuration to use
296 * @param name name to look up
297 * @param cb callback to invoke with the result
298 * @param cb_cls closure for @a cb
299 * @return NULL on error
300 */
301struct GNUNET_IDENTITY_EgoLookup *
302GNUNET_IDENTITY_ego_lookup (const struct GNUNET_CONFIGURATION_Handle *cfg,
303 const char *name,
304 GNUNET_IDENTITY_EgoCallback cb,
305 void *cb_cls);
306
307
308/**
309 * Abort ego lookup attempt.
310 *
311 * @param el handle for lookup to abort
312 */
313void
314GNUNET_IDENTITY_ego_lookup_cancel (struct GNUNET_IDENTITY_EgoLookup *el);
315
316
275#if 0 /* keep Emacsens' auto-indent happy */ 317#if 0 /* keep Emacsens' auto-indent happy */
276{ 318{
277#endif 319#endif