aboutsummaryrefslogtreecommitdiff
path: root/src/include
diff options
context:
space:
mode:
authorMatthias Wachs <wachs@net.in.tum.de>2011-11-29 15:43:11 +0000
committerMatthias Wachs <wachs@net.in.tum.de>2011-11-29 15:43:11 +0000
commit0c3e3371bcc2dad9c4f14561068a1752f01b1756 (patch)
tree6aa926c5f1ad962594f6c9ad9b238500ad644702 /src/include
parentfd2601f3fce6eefbb7e0f9aaca61f9169b25d3f4 (diff)
downloadgnunet-0c3e3371bcc2dad9c4f14561068a1752f01b1756.tar.gz
gnunet-0c3e3371bcc2dad9c4f14561068a1752f01b1756.zip
- latest changes for refactoring: iterate sends disassembled hello-address
Diffstat (limited to 'src/include')
-rw-r--r--src/include/gnunet_protocols.h11
-rw-r--r--src/include/gnunet_transport_service.h15
2 files changed, 14 insertions, 12 deletions
diff --git a/src/include/gnunet_protocols.h b/src/include/gnunet_protocols.h
index 81b5ce6b8..f386d8768 100644
--- a/src/include/gnunet_protocols.h
+++ b/src/include/gnunet_protocols.h
@@ -1020,12 +1020,12 @@ extern "C"
1020/** 1020/**
1021 * Request to look addresses of peers in server. 1021 * Request to look addresses of peers in server.
1022 */ 1022 */
1023#define GNUNET_MESSAGE_TYPE_TRANSPORT_ADDRESS_LOOKUP 367 1023#define GNUNET_MESSAGE_TYPE_TRANSPORT_ADDRESS_TO_STRING 367
1024 1024
1025/** 1025/**
1026 * Response to the address lookup request. 1026 * Response to the address lookup request.
1027 */ 1027 */
1028#define GNUNET_MESSAGE_TYPE_TRANSPORT_ADDRESS_REPLY 368 1028#define GNUNET_MESSAGE_TYPE_TRANSPORT_ADDRESS_TO_STRING_REPLY 368
1029 1029
1030/** 1030/**
1031 * Register a client that wants to do blacklisting. 1031 * Register a client that wants to do blacklisting.
@@ -1106,9 +1106,14 @@ extern "C"
1106 1106
1107 1107
1108/** 1108/**
1109 * Request to iterate over all known addresses.
1110 */
1111#define GNUNET_MESSAGE_TYPE_TRANSPORT_ADDRESS_ITERATE_RESPONSE 383
1112
1113/**
1109 * Message send by a peer to notify the other to keep the session alive. 1114 * Message send by a peer to notify the other to keep the session alive.
1110 */ 1115 */
1111#define GNUNET_MESSAGE_TYPE_TRANSPORT_BROADCAST_BEACON 383 1116#define GNUNET_MESSAGE_TYPE_TRANSPORT_BROADCAST_BEACON 384
1112 1117
1113 1118
1114/** 1119/**
diff --git a/src/include/gnunet_transport_service.h b/src/include/gnunet_transport_service.h
index 7e7fc7fa6..98436065b 100644
--- a/src/include/gnunet_transport_service.h
+++ b/src/include/gnunet_transport_service.h
@@ -112,12 +112,8 @@ typedef void (*GNUNET_TRANSPORT_AddressToStringCallback) (void *cls,
112 * Function to call with a binary format of an address 112 * Function to call with a binary format of an address
113 * 113 *
114 * @param cls closure 114 * @param cls closure
115 * @param peer peer identity 115 * @param address address
116 * @param transport transport plugin
117 * @param addr address
118 * @param addrlen address length
119 */ 116 */
120// FIXME: use GNUNET_HELLO_Address (as 2nd arg, replacing others)
121// FIXME: use NULL for address on disconnect IF in monitor mode (one_shot = NO) 117// FIXME: use NULL for address on disconnect IF in monitor mode (one_shot = NO)
122typedef void (*GNUNET_TRANSPORT_AddressLookUpCallback) (void *cls, 118typedef void (*GNUNET_TRANSPORT_AddressLookUpCallback) (void *cls,
123 const struct GNUNET_HELLO_Address *address); 119 const struct GNUNET_HELLO_Address *address);
@@ -310,17 +306,18 @@ GNUNET_TRANSPORT_address_to_string_cancel (struct
310 306
311 307
312/** 308/**
313 * Return all the known addresses for a peer. 309 * Return all the known addresses for a specific peer or all peers.
310 * Returns continously all address if one_shot is set to GNUNET_NO
311 *
314 * CHANGE: Returns the address(es) that we are currently using for this 312 * CHANGE: Returns the address(es) that we are currently using for this
315 * peer. Upon completion, the 'AddressLookUpCallback' is called one more 313 * peer. Upon completion, the 'AddressLookUpCallback' is called one more
316 * time with 'NULL' for the address and the peer. After this, the operation must no 314 * time with 'NULL' for the address and the peer. After this, the operation must no
317 * longer be explicitly cancelled. 315 * longer be explicitly cancelled.
318 * TODO: change code that uses this API to see if this is fine...
319 * 316 *
320 * @param cfg configuration to use 317 * @param cfg configuration to use
321 * @param peer peer identity to look up the addresses of, CHANGE: allow NULL for all (connected) peers 318 * @param peer peer identity to look up the addresses of, CHANGE: allow NULL for all (connected) peers
322 * FIXME: @param one_shot GNUNET_YES to return the current state and then end (with NULL+NULL), 319 * @param one_shot GNUNET_YES to return the current state and then end (with NULL+NULL),
323 * GNUNET_NO to monitor the set of addresses used (continuously, must be explicitly cancelled) 320 * GNUNET_NO to monitor the set of addresses used (continuously, must be explicitly cancelled)
324 * @param timeout how long is the lookup allowed to take at most 321 * @param timeout how long is the lookup allowed to take at most
325 * @param peer_address_callback function to call with the results 322 * @param peer_address_callback function to call with the results
326 * @param peer_address_callback_cls closure for peer_address_callback 323 * @param peer_address_callback_cls closure for peer_address_callback