2 This file is part of GNUnet.
3 Copyright (C) 2013, 2017 GNUnet e.V.
5 GNUnet is free software: you can redistribute it and/or modify it
6 under the terms of the GNU Affero General Public License as published
7 by the Free Software Foundation, either version 3 of the License,
8 or (at your option) any later version.
10 GNUnet is distributed in the hope that it will be useful, but
11 WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Affero General Public License for more details.
15 You should have received a copy of the GNU Affero General Public License
16 along with this program. If not, see <http://www.gnu.org/licenses/>.
18 SPDX-License-Identifier: AGPL3.0-or-later
22 * @file cadet/gnunet-service-cadet_dht.h
23 * @brief cadet service; dealing with DHT requests and results
24 * @author Bartlomiej Polot
25 * @author Christian Grothoff
27 * All functions in this file should use the prefix GCD (Gnunet Cadet Dht)
29 #ifndef GNUNET_SERVICE_CADET_DHT_H
30 #define GNUNET_SERVICE_CADET_DHT_H
35 #if 0 /* keep Emacsens' auto-indent happy */
41 #include "gnunet_util_lib.h"
44 * Handle for DHT search operation.
46 struct GCD_search_handle;
50 * Initialize the DHT subsystem.
52 * @param c Configuration.
55 GCD_init (const struct GNUNET_CONFIGURATION_Handle *c);
59 * Shut down the DHT subsystem.
66 * Function called by the HELLO subsystem whenever OUR hello
67 * changes. Re-triggers the DHT PUT immediately.
70 GCD_hello_update (void);
73 * Search DHT for paths to @a peeR_id
75 * @param peer_id peer to search for
76 * @return handle to abort search
78 struct GCD_search_handle *
79 GCD_search (const struct GNUNET_PeerIdentity *peer_id);
83 * Stop DHT search started with #GCD_search().
85 * @param h handle to search to stop
88 GCD_search_stop (struct GCD_search_handle *h);
91 #if 0 /* keep Emacsens' auto-indent happy */
98 /* ifndef GNUNET_CADET_SERVICE_DHT_H */
100 /* end of gnunet-service-cadet_dht.h */