diff options
author | Christian Grothoff <christian@grothoff.org> | 2018-05-30 18:47:17 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2018-05-30 18:47:17 +0200 |
commit | adef29b3ed00afd42669ae35a73951c59f08a41b (patch) | |
tree | c8d6c7f60716c551b587aed7a1efe0d6e756833f /src/dht/gnunet-service-dht_neighbours.h | |
parent | f5a18b7466f342ac9624adcdb65f104aef8ecb5e (diff) | |
download | gnunet-adef29b3ed00afd42669ae35a73951c59f08a41b.tar.gz gnunet-adef29b3ed00afd42669ae35a73951c59f08a41b.zip |
add proximity considerations to datacache
Diffstat (limited to 'src/dht/gnunet-service-dht_neighbours.h')
-rw-r--r-- | src/dht/gnunet-service-dht_neighbours.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/dht/gnunet-service-dht_neighbours.h b/src/dht/gnunet-service-dht_neighbours.h index 34b76ee8a..bb1867fe9 100644 --- a/src/dht/gnunet-service-dht_neighbours.h +++ b/src/dht/gnunet-service-dht_neighbours.h | |||
@@ -123,6 +123,22 @@ GDS_NEIGHBOURS_handle_reply (const struct GNUNET_PeerIdentity *target, | |||
123 | 123 | ||
124 | 124 | ||
125 | /** | 125 | /** |
126 | * Check whether my identity is closer than any known peers. If a | ||
127 | * non-null bloomfilter is given, check if this is the closest peer | ||
128 | * that hasn't already been routed to. | ||
129 | * | ||
130 | * @param key hash code to check closeness to | ||
131 | * @param bloom bloomfilter, exclude these entries from the decision | ||
132 | * @return #GNUNET_YES if node location is closest, | ||
133 | * #GNUNET_NO otherwise. | ||
134 | */ | ||
135 | int | ||
136 | GDS_am_closest_peer (const struct GNUNET_HashCode *key, | ||
137 | const struct GNUNET_CONTAINER_BloomFilter *bloom); | ||
138 | |||
139 | |||
140 | |||
141 | /** | ||
126 | * Initialize neighbours subsystem. | 142 | * Initialize neighbours subsystem. |
127 | * | 143 | * |
128 | * @return #GNUNET_OK on success, #GNUNET_SYSERR on error | 144 | * @return #GNUNET_OK on success, #GNUNET_SYSERR on error |