Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Update copyright lines with new year.
[simgrid.git] / examples / deprecated / msg / dht-kademlia / dht-kademlia.h
1 /* Copyright (c) 2012-2020. The SimGrid Team.
2  * All rights reserved.                                                     */
3
4 /* This program is free software; you can redistribute it and/or modify it
5  * under the terms of the license (GNU LGPL) which comes with this package. */
6
7 #ifndef _MSG_EXAMPLES_KADEMLIA_H
8 #define _MSG_EXAMPLES_KADEMLIA_H
9 #include "node.h"
10 #include "task.h"
11
12 //core kademlia functions
13 unsigned int join(node_t node, unsigned int id_known);
14 unsigned int find_node(node_t node, unsigned int id_to_find, unsigned int count_in_stats);
15 void random_lookup(node_t node);
16
17 void send_find_node(node_t node, unsigned int id, unsigned int destination);
18 unsigned int send_find_node_to_best(node_t node, const_answer_t node_list);
19
20 void handle_task(node_t node, msg_task_t task);
21 void handle_find_node(node_t node, const_task_data_t data);
22
23 #endif                          /* _MSG_EXAMPLES_KADEMLIA_H */