Imported Robodoc.
[robodoc.git] / Source / links.h
1 #ifndef ROBODOC_LINKS_H
2 #define ROBODOC_LINKS_H
3
4 /*
5 Copyright (C) 1994-2007  Frans Slothouber, Jacco van Weert, Petteri Kettunen,
6 Bernd Koesling, Thomas Aglassinger, Anthon Pang, Stefan Kost, David Druffner,
7 Sasha Vasko, Kai Hofmann, Thierry Pierron, Friedrich Haase, and Gergely Budai.
8
9 This file is part of ROBODoc
10
11 ROBODoc is free software; you can redistribute it and/or modify
12 it under the terms of the GNU General Public License as published by
13 the Free Software Foundation; either version 3 of the License, or
14 (at your option) any later version.
15
16 This program is distributed in the hope that it will be useful,
17 but WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
19 GNU General Public License for more details.
20
21 You should have received a copy of the GNU General Public License
22 along with this program.  If not, see <http://www.gnu.org/licenses/>.
23
24 */
25
26
27 #include "headertypes.h"
28 #include "headers.h"
29 #include "document.h"
30
31 /****s* Links/RB_link
32  *  NAME
33  *    RB_link -- link data structure
34  *  PURPOSE
35  *    Structure to store links to the documentation of an component.
36  *  ATTRIBUTES
37  *    * label_name  -- the label under which the component can be found.
38  *                     this should be a unique name.
39  *    * object_name -- the proper name of the object
40  *    * file_name   -- the file the component can be found in.
41  *    * type        -- the type of component (the header type).
42  *    * is_internal -- is the header an internal header?
43  *  SOURCE
44  */
45
46 struct RB_link
47 {
48     char               *label_name;
49     char               *object_name;
50     char               *file_name;
51     struct RB_HeaderType *htype;
52     int                 is_internal;
53 };
54
55 /*********/
56
57 int                 Find_Link(
58     char *word_begin,
59     char **object_name,
60     char **unique_name,
61     char **file_name );
62 void                RB_CollectLinks(
63     struct RB_Document *document,
64     struct RB_header **headers,
65     unsigned long count );
66 void                RB_Free_Links(
67     void );
68 void                RB_Free_Link(
69     struct RB_link *arg_link );
70
71 int                 RB_Number_Of_Links(
72     struct RB_HeaderType *header_type,
73     char *file_name,
74     int internal );
75
76 #endif /* ROBODOC_LINKS_H */