Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
gml_scanner.h
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file gml_scanner.h
1 /* This software is distributed under the GNU Lesser General Public License */
2 //==========================================================================
3 //
4 // gml_scanner.h
5 //
6 //==========================================================================
7 // $Id: gml_scanner.h,v 1.11 2000/03/06 15:16:52 raitner Exp $
8 
9 #ifndef GTL_GML_SCANNER_H
10 #define GTL_GML_SCANNER_H
11 
12 #include <GTL/GTL.h>
13 
14 #include <cstdio>
15 
17 
18 /*
19  * start-size of buffers for reading strings. If too small it will be enlarged
20  * dynamically
21  */
22 
23 #define INITIAL_SIZE 1024
24 
25 GTL_EXTERN typedef enum {
28 } GML_value;
29 
30 
34 GTL_EXTERN typedef enum {
38 
39 
78 
84  int line;
85 
89  int column;
90 };
91 
92 
94  long integer;
95  double floating;
96  char* str;
97  struct GML_error err;
98 };
99 
106 };
107 
108 /*
109  * global variables
110  */
111 
112 GTL_EXTERN extern unsigned int GML_line;
113 GTL_EXTERN extern unsigned int GML_column;
114 
115 /*
116  * if you are interested in the position where an error occured it is a good
117  * idea to set GML_line and GML_column back.
118  * This is what GML_init does.
119  */
120 
121 GTL_EXTERN void GML_init ();
122 
123 /*
124  * returns the next token in file. If an error occured it will be stored in
125  * GML_token.
126  */
127 
128 GTL_EXTERN struct GML_token GML_scanner (FILE*);
129 
130 GTL_EXTERN extern const char* GML_table[];
131 
133 
134 #endif // GTL_GML_SCANNER_H
135 
136 //--------------------------------------------------------------------------
137 // end of file
138 //--------------------------------------------------------------------------