Qucs-core  0.0.18
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
check_mdl.h
Go to the documentation of this file.
1 /*
2  * check_mdl.h - checker definitions for an IC-CAP MDL file
3  *
4  * Copyright (C) 2006 Stefan Jahn <stefan@lkcc.org>
5  *
6  * This is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2, or (at your option)
9  * any later version.
10  *
11  * This software is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this package; see the file COPYING. If not, write to
18  * the Free Software Foundation, Inc., 51 Franklin Street - Fifth Floor,
19  * Boston, MA 02110-1301, USA.
20  *
21  * $Id$
22  *
23  */
24 
25 #ifndef __CHECK_MDL_H__
26 #define __CHECK_MDL_H__
27 
28 namespace qucs {
29  class dataset;
30 }
31 
32 /* Externalize variables used by the scanner and parser. */
33 extern int mdl_lineno;
34 extern FILE * mdl_in;
35 void mdl_restart (FILE *);
36 
37 __BEGIN_DECLS
38 
39 /* Available functions of the checker. */
40 int mdl_check (void);
41 int mdl_parse (void);
42 int mdl_error (const char *);
43 int mdl_lex (void);
44 int mdl_lex_destroy (void);
45 void mdl_destroy (void);
46 void mdl_init (void);
47 
48 __END_DECLS
49 
50 /* Declaration of MDL data structures. */
51 extern qucs::dataset * mdl_result;
52 extern struct mdl_link_t * mdl_root;
53 extern struct mdl_sync_t * mdl_sync_root;
54 
55 struct mdl_point_t {
56  int n;
57  int x;
58  int y;
59  double r;
60  double i;
61  struct mdl_point_t * next;
62 };
63 
65  char * type;
66  int size;
67  int x;
68  int y;
69 };
70 
71 struct mdl_element_t {
72  int number;
73  char * name;
74  char * value;
75  char * attr;
76  struct mdl_element_t * next;
77 };
78 
80  char * name;
81  struct mdl_element_t * data;
82 };
83 
84 struct mdl_table_t {
85  char * name;
86  struct mdl_element_t * data;
87 };
88 
89 struct mdl_dataset_t {
90  char * type1;
91  struct mdl_point_t * data1;
92  char * type2;
93  struct mdl_point_t * data2;
95 };
96 
97 struct mdl_link_t {
98  struct mdl_link_t * parent;
99  char * name;
100  char * type;
102  struct mdl_link_t * next;
103 };
104 
106  int type;
107  union {
108  struct mdl_link_t * link;
109  struct mdl_data_t * data;
110  struct mdl_table_t * table;
111  };
113 };
114 
115 struct mdl_data_t {
117 };
118 
120  int type;
121  union {
122  struct mdl_dataset_t * data;
124  };
126 };
127 
128 struct mdl_sync_t {
129  char * master;
130  char * name;
131  double ratio;
132  double offset;
133  struct mdl_sync_t * next;
134 };
135 
136 #endif /* __CHECK_MDL_H__ */
struct mdl_sync_t * next
Definition: check_mdl.h:133
double ratio
Definition: check_mdl.h:131
FILE * mdl_in
char * attr
Definition: check_mdl.h:75
double r
Definition: check_mdl.h:59
int mdl_parse(void)
struct mdl_element_t * next
Definition: check_mdl.h:76
struct mdl_dcontent_t * next
Definition: check_mdl.h:125
struct mdl_data_t * data
Definition: check_mdl.h:109
struct mdl_dcontent_t * content
Definition: check_mdl.h:116
struct mdl_link_t * link
Definition: check_mdl.h:108
int mdl_lex_destroy(void)
void mdl_init(void)
Definition: check_mdl.cpp:695
struct mdl_element_t * data
Definition: check_mdl.h:81
struct mdl_point_t * data2
Definition: check_mdl.h:93
struct mdl_point_t * next
Definition: check_mdl.h:61
struct mdl_dataset_t * data
Definition: check_mdl.h:122
struct mdl_link_t * mdl_root
Definition: check_mdl.cpp:53
int mdl_lineno
struct mdl_point_t * data1
Definition: check_mdl.h:91
struct mdl_hyptable_t * hyptable
Definition: check_mdl.h:123
void mdl_restart(FILE *)
__END_DECLS qucs::dataset * mdl_result
Definition: check_mdl.cpp:52
void mdl_destroy(void)
Definition: check_mdl.cpp:672
__BEGIN_DECLS int mdl_check(void)
Definition: check_mdl.cpp:658
double offset
Definition: check_mdl.h:132
double i
Definition: check_mdl.h:60
char * type2
Definition: check_mdl.h:92
int mdl_error(const char *)
Definition: parse_mdl.y:620
char * type
Definition: check_mdl.h:65
struct mdl_table_t * table
Definition: check_mdl.h:110
char * master
Definition: check_mdl.h:129
struct mdl_element_t * data
Definition: check_mdl.h:86
char * name
Definition: check_mdl.h:130
struct mdl_lcontent_t * next
Definition: check_mdl.h:112
int mdl_lex(void)
char * name
Definition: check_mdl.h:80
char * value
Definition: check_mdl.h:74
char * type1
Definition: check_mdl.h:90
struct mdl_datasize_t * dsize
Definition: check_mdl.h:94
struct mdl_sync_t * mdl_sync_root
Definition: check_mdl.cpp:54
char * name
Definition: check_mdl.h:85
char * name
Definition: check_mdl.h:73