aboutsummaryrefslogtreecommitdiff
path: root/src/include/gnunet_messenger_service.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/include/gnunet_messenger_service.h')
-rw-r--r--src/include/gnunet_messenger_service.h21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/include/gnunet_messenger_service.h b/src/include/gnunet_messenger_service.h
index 0576e239f..ad5cc4f12 100644
--- a/src/include/gnunet_messenger_service.h
+++ b/src/include/gnunet_messenger_service.h
@@ -50,6 +50,8 @@ extern "C" {
50 50
51/** 51/**
52 * Version number of GNUnet Messenger API. 52 * Version number of GNUnet Messenger API.
53 *
54 * Current version of the Messenger: 0.1
53 */ 55 */
54#define GNUNET_MESSENGER_VERSION 0x00000001 56#define GNUNET_MESSENGER_VERSION 0x00000001
55 57
@@ -219,6 +221,10 @@ struct GNUNET_MESSENGER_MessageInfo
219 221
220 /** 222 /**
221 * The version of GNUnet Messenger API. 223 * The version of GNUnet Messenger API.
224 *
225 * The sixteen lower bits represent the lower version number while the sixteen higher bits
226 * represent the higher version number. A different higher version number implies imcompatibility
227 * to lower versions while differences in the lower version can still be supported potentially.
222 */ 228 */
223 uint32_t messenger_version; 229 uint32_t messenger_version;
224}; 230};
@@ -672,6 +678,21 @@ void
672GNUNET_MESSENGER_close_room (struct GNUNET_MESSENGER_Room *room); 678GNUNET_MESSENGER_close_room (struct GNUNET_MESSENGER_Room *room);
673 679
674/** 680/**
681 * Searches for a specific <i>contact</i> in a given <i>room</i> and calls a selected <i>callback</i> with a given
682 * closure for each of them containing the contact as a member. The callback will receive a room matching the condition
683 * and the given contact. The function returns the amount of rooms iterated with the given callback.
684 *
685 * @param[in] handle Messenger handle to use
686 * @param[in] contact Contact handle
687 * @param[in] callback Function called for each room
688 * @param[in] cls Closure for the <i>callback</i> handler
689 * @return Amount of rooms iterated
690 */
691int
692GNUNET_MESSENGER_find_rooms (const struct GNUNET_MESSENGER_Handle *handle, const struct GNUNET_MESSENGER_Contact *contact,
693 GNUNET_MESSENGER_MemberCallback callback, void *cls);
694
695/**
675 * Get the contact of a member in a <i>room</i> which sent a specific message identified with a given <i>hash</i>. 696 * Get the contact of a member in a <i>room</i> which sent a specific message identified with a given <i>hash</i>.
676 * 697 *
677 * Notice that contacts are independent of rooms but will be removed if all rooms containing these contacts get closed. 698 * Notice that contacts are independent of rooms but will be removed if all rooms containing these contacts get closed.