#ifndef LUT_H_FILE_H #define LUT_H_FILE_H static char *p_lut_h = { " \n\ \n\ /*----------------------------------------------------------- \n\ * \n\ * Source File : lut.h \n\ * (removed ':' after #define bool... - RJL 96/4/16) \n\ *----------------------------------------------------------- \n\ */ \n\ \n\ #define bool unsigned char \n\ \n\ #ifndef ERROR \n\ #define ERROR -1 \n\ #endif \n\ \n\ #ifndef TRUE \n\ #define TRUE (bool) 1 \n\ #define FALSE (bool) 0 \n\ #endif \n\ \n\ #define ABBR_SIZE_BIG 4 /* num char in abbr name */ \n\ #define VER_SIZE 3 /* num char in version name */ \n\ #define ABBR_SIZE_SMALL 2 /* num char in abbr name */ \n\ #define ARR_SIZE ABBR_SIZE_BIG \n\ \n\ #ifdef MAXTABLES \n\ #define LUT_NUM_ELEMENTS MAXTABLES \n\ #else \n\ #define LUT_NUM_ELEMENTS 256 /* max num elements in lut */ \n\ #endif \n\ \n\ #define MAX_VER_ELEMENTS 100 /* max allowed elements in version lut */ \n\ #define MAX_VER_NUMBER 999 /* Highest version number allowed... */ \n\ \n\ typedef struct btree_node_st btree_node_st; \n\ \n\ /*****************************************************************/ \n\ /* the following structure is used as a binary tree node element */ \n\ /*****************************************************************/ \n\ struct btree_node_st \n\ { \n\ char name[ARR_SIZE+1]; \n\ unsigned char num; \n\ int weight; \n\ btree_node_st *p_right; /* ptr to right child */ \n\ btree_node_st *p_left; /* ptr to left child */ \n\ btree_node_st *p_parent; /* ptr to parent */ \n\ }; \n\ \n\ \n\ /***********************************/ \n\ /* the following structure is used */ \n\ /* as a look up table structure */ \n\ /***********************************/ \n\ \n\ typedef char C_TABLE[ARR_SIZE + 1]; \n\ \n\ \n\ typedef enum \n\ { \n\ ABBR_TBL_TYPE = 777, /* abbreviation table type */ \n\ VER_TBL_TYPE /* version number type */ \n\ } lut_type; \n\ \n\ \n\ \n\ typedef struct \n\ { \n\ int num_elements; /* num elements currently in lut. */ \n\ lut_type type; \n\ btree_node_st *p_btree_root; /* ptr to root of btree */ \n\ C_TABLE names[LUT_NUM_ELEMENTS]; /* look up table */ \n\ }lut_st; \n\ \n\ \n\ " }; /* end of character string definition */ #endif