Remove unused variables
[onak.git] / stats.h
1 /*
2  * stats.c - various routines to do stats on the key graph
3  *
4  * Jonathan McDowell <noodles@earth.li>
5  *
6  * Copyright 2002 Project Purple
7  */
8
9 /* MOSTSIGNED
10 SIGNSMOST
11 SIGNS <key>
12 SIGS <key>
13 SIXDEGREES <keyid>
14 MAXPATH
15
16 key_getsigs - get the sigs for a key.
17 key_getsigns - get the keys a key signs. */
18
19 #ifndef __STATS_H__
20 #define __STATS_H__
21
22 #include <inttypes.h>
23 #include <stdbool.h>
24
25 #include "keystructs.h"
26 #include "ll.h"
27
28 /**
29  *      initcolour - Clear the key graph ready for use.
30  *      @parent: Do we want to clear the parent pointers too?
31  *
32  *      Clears the parent and colour information on all elements in the key
33  *      graph.
34  */
35 void initcolour(bool parent);
36
37 /**
38  *      findpath - Given 2 keys finds a path between them.
39  *      @have: The key we have.
40  *      @want: The key we want to get to.
41  *
42  *      This does a breadth first search on the key tree, starting with the
43  *      key we have. It returns as soon as a path is found or when we run out
44  *      of keys; whichever comes sooner.
45  */
46 unsigned long findpath(struct stats_key *have, struct stats_key *want);
47
48 /**
49  *      dofindpath - Given 2 keys displays a path between them.
50  *      @have: The key we have.
51  *      @want: The key we want to get to.
52  *      @html: Should we output in html.
53  *      @count: How many paths we should look for at most.
54  *
55  *      This does a breadth first search on the key tree, starting with the
56  *      key we have. It returns as soon as a path is found or when we run out
57  *      of keys; whichever comes sooner.
58  */
59 void dofindpath(uint64_t have, uint64_t want, bool html, int count);
60
61 struct stats_key *furthestkey(struct stats_key *have);
62
63 #endif /* __STATS_H__ */