You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
120 lines
4.0 KiB
120 lines
4.0 KiB
#ifndef MIFPARSE
|
|
#define MIFPARSE
|
|
|
|
/* ===========================================================================
|
|
FILE MIFparse.h
|
|
|
|
MEMBER OF process XSPICE
|
|
|
|
Copyright 1991
|
|
Georgia Tech Research Corporation
|
|
Atlanta, Georgia 30332
|
|
All Rights Reserved
|
|
|
|
PROJECT A-8503
|
|
|
|
AUTHORS
|
|
|
|
9/12/91 Bill Kuhn
|
|
|
|
MODIFICATIONS
|
|
|
|
<date> <person name> <nature of modifications>
|
|
|
|
SUMMARY
|
|
|
|
This file contains the information structure definitions used by the
|
|
code model parser to check for valid connections and parameters.
|
|
|
|
Structures of these types are created by the code model preprocessor
|
|
(cmpp) from the user created ifspec.ifs file.
|
|
|
|
INTERFACES
|
|
|
|
None.
|
|
|
|
REFERENCED FILES
|
|
|
|
None.
|
|
|
|
NON-STANDARD FEATURES
|
|
|
|
None.
|
|
|
|
=========================================================================== */
|
|
|
|
|
|
#include "miftypes.h"
|
|
|
|
|
|
/*
|
|
* Information about a connection used by the parser to error check input
|
|
*/
|
|
|
|
|
|
typedef struct Mif_Conn_Info_s {
|
|
|
|
char *name; /* Name of this connection */
|
|
char *description; /* Description of this connection */
|
|
Mif_Dir_t direction; /* Is this connection an input, output, or both? */
|
|
Mif_Port_Type_t default_port_type; /* The default port type */
|
|
char *default_type; /* The default type in string form */
|
|
int num_allowed_types; /* The size of the allowed type arrays */
|
|
Mif_Port_Type_t *allowed_type; /* The allowed types */
|
|
char **allowed_type_str; /* The allowed types in string form */
|
|
Mif_Boolean_t is_array; /* True if connection is an array */
|
|
Mif_Boolean_t has_lower_bound; /* True if there is an array size lower bound */
|
|
int lower_bound; /* Array size lower bound */
|
|
Mif_Boolean_t has_upper_bound; /* True if there is an array size upper bound */
|
|
int upper_bound; /* Array size upper bound */
|
|
Mif_Boolean_t null_allowed; /* True if null is allowed for this connection */
|
|
|
|
} Mif_Conn_Info_t;
|
|
|
|
|
|
|
|
|
|
/*
|
|
* Information about a parameter used by the parser to error check input
|
|
*/
|
|
|
|
typedef struct Mif_Param_Info_s {
|
|
|
|
char *name; /* Name of this parameter */
|
|
char *description; /* Description of this parameter */
|
|
Mif_Data_Type_t type; /* Is this a real, boolean, string, ... */
|
|
Mif_Boolean_t has_default; /* True if there is a default value */
|
|
Mif_Parse_Value_t default_value; /* The default value */
|
|
Mif_Boolean_t has_lower_limit; /* True if there is a lower limit */
|
|
Mif_Parse_Value_t lower_limit; /* The lower limit for this parameter */
|
|
Mif_Boolean_t has_upper_limit; /* True if there is a upper limit */
|
|
Mif_Parse_Value_t upper_limit; /* The upper limit for this parameter */
|
|
Mif_Boolean_t is_array; /* True if parameter is an array */
|
|
Mif_Boolean_t has_conn_ref; /* True if parameter is associated with a connector */
|
|
int conn_ref; /* The subscript of the associated connector */
|
|
Mif_Boolean_t has_lower_bound; /* True if there is an array size lower bound */
|
|
int lower_bound; /* Array size lower bound */
|
|
Mif_Boolean_t has_upper_bound; /* True if there is an array size upper bound */
|
|
int upper_bound; /* Array size upper bound */
|
|
Mif_Boolean_t null_allowed; /* True if null is allowed for this parameter */
|
|
|
|
} Mif_Param_Info_t;
|
|
|
|
|
|
|
|
|
|
/*
|
|
* Information about an instance parameter used by the parser to error check input
|
|
*/
|
|
|
|
typedef struct Mif_Inst_Var_Info_s {
|
|
|
|
char *name; /* Name of this instance var */
|
|
char *description; /* Description of this instance var */
|
|
Mif_Data_Type_t type; /* Is this a real, boolean, string, ... */
|
|
Mif_Boolean_t is_array; /* True if instance var is an array */
|
|
|
|
} Mif_Inst_Var_Info_t;
|
|
|
|
|
|
#endif /* MIFPARSE */
|