Subversion Repositories tendra.SVN

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
2 7u83 1
/*
2
    		 Crown Copyright (c) 1997
3
 
4
    This TenDRA(r) Computer Program is subject to Copyright
5
    owned by the United Kingdom Secretary of State for Defence
6
    acting through the Defence Evaluation and Research Agency
7
    (DERA).  It is made available to Recipients with a
8
    royalty-free licence for its use, reproduction, transfer
9
    to other parties and amendment for any purpose not excluding
10
    product development provided that any such use et cetera
11
    shall be deemed to be acceptance of the following conditions:-
12
 
13
        (1) Its Recipients shall ensure that this Notice is
14
        reproduced upon any copies or amended versions of it;
15
 
16
        (2) Any amended version of it shall be clearly marked to
17
        show both the nature of and the organisation responsible
18
        for the relevant amendment or amendments;
19
 
20
        (3) Its onward transfer from a recipient to another
21
        party shall be deemed to be that party's acceptance of
22
        these conditions;
23
 
24
        (4) DERA gives no warranty or assurance as to its
25
        quality or suitability for any purpose and DERA accepts
26
        no liability whatsoever in relation to any use to which
27
        it may be put.
28
*/
29
 
30
 
31
/*** table.h --- Identifier table ADT.
32
 *
33
 ** Author: Steve Folkes <smf@hermes.mod.uk>
34
 *
35
 *** Commentary:
36
 *
37
 * See the file "table.c" for more information.
38
 *
39
 *** Change Log:
40
 * $Log: table.h,v $
41
 * Revision 1.1.1.1  1998/01/17  15:57:47  release
42
 * First version to be checked into rolling release.
43
 *
44
 * Revision 1.2  1994/12/15  09:59:07  smf
45
 * Brought into line with OSSG C Coding Standards Document, as per
46
 * "CR94_178.sid+tld-update".
47
 *
48
 * Revision 1.1.1.1  1994/07/25  16:04:43  smf
49
 * Initial import of SID 1.8 non shared files.
50
 *
51
**/
52
 
53
/****************************************************************************/
54
 
55
#ifndef H_TABLE
56
#define H_TABLE
57
 
58
#include "os-interface.h"
59
#include "dstring.h"
60
#include "entry.h"
61
#include "ostream.h"
62
#include "key.h"
63
 
64
/* To avoid cicularity: */
65
struct GrammarT;
66
 
67
/*--------------------------------------------------------------------------*/
68
 
69
#define TABLE_SIZE (127)
70
 
71
/*--------------------------------------------------------------------------*/
72
 
73
typedef struct TableT {
74
    EntryP			contents [TABLE_SIZE];
75
} TableT, *TableP;
76
 
77
/*--------------------------------------------------------------------------*/
78
 
79
extern void			table_init
80
	PROTO_S ((TableP));
81
extern EntryP			table_add_type
82
	PROTO_S ((TableP, NStringP));
83
extern EntryP			table_add_basic
84
	PROTO_S ((TableP, NStringP, struct GrammarT *, BoolT));
85
extern EntryP			table_add_action
86
	PROTO_S ((TableP, NStringP));
87
extern EntryP			table_add_rule
88
	PROTO_S ((TableP, NStringP));
89
extern EntryP			table_add_generated_rule
90
	PROTO_S ((TableP, BoolT));
91
extern EntryP			table_add_name
92
	PROTO_S ((TableP, NStringP));
93
extern EntryP			table_add_generated_name
94
	PROTO_S ((TableP));
95
extern EntryP			table_add_rename
96
	PROTO_S ((TableP));
97
extern EntryP			table_add_non_local
98
	PROTO_S ((TableP, NStringP, EntryP));
99
extern EntryP			table_get_entry
100
	PROTO_S ((TableP, NStringP));
101
extern EntryP			table_get_type
102
	PROTO_S ((TableP, NStringP));
103
extern EntryP			table_get_basic
104
	PROTO_S ((TableP, NStringP));
105
extern EntryP			table_get_basic_by_number
106
	PROTO_S ((TableP, unsigned));
107
extern EntryP			table_get_action
108
	PROTO_S ((TableP, NStringP));
109
extern EntryP			table_get_rule
110
	PROTO_S ((TableP, NStringP));
111
extern void			table_iter
112
	PROTO_S ((TableP, void (*) (EntryP, GenericP), GenericP));
113
extern void			table_untrace
114
	PROTO_S ((TableP));
115
extern void			table_unlink_untraced_rules
116
	PROTO_S ((TableP));
117
 
118
#endif /* !defined (H_TABLE) */
119
 
120
/*
121
 * Local variables(smf):
122
 * eval: (include::add-path-entry "../os-interface" "../library")
123
 * eval: (include::add-path-entry "../generated")
124
 * end:
125
**/