/* This .H file is generated by H_GEN.C from housedb.txt H_GEN.C is suitable for free_format schema.txt While old version H_GEN_BAK is suitable only for fixed format schema.txt Modify by TCHENG & CCHOU 07/JULY 1989 */ #define schema_text_file_name housedb.txt #define schema_header_file_name housedb.h #define BUFSIZE 256 #define NAMELENGTH 20 #define MAXFIELDNO 20 #define ABBREV_NAME_LENGTH 3 FILE *hcg_fp1 , *hcg_fp2 ; struct dummy_type { int dummy ; } ; struct hcg_table_seq_list_type { char ttabbrev[ABBREV_NAME_LENGTH] ; struct hcg_table_seq_list_type *next_ptr ; } *hcg_table_seq_list = NULL, *hcg_curr_table_ptr ; static char hcg_s[ABBREV_NAME_LENGTH] = " " ; char hcg_dummy_char , hcg_buffer[BUFSIZE] , hcg_t[MAXFIELDNO][NAMELENGTH] ; /* pc_table entries : parent followed by child AYid:AVid CAid:AYid CAid:APid CFid:FYid CFid:FUid CSid:CJid CUid:UTid FYid:FVid HOid:UTid HOid:SSid HOid:ROid HOid:PAid JPid:OUid JPid:CJid PAid:SUid PAid:CSid PAid:APid ROid:SUid SUid:OUid SUid:FUid TTid:SSid UTid:CSid */ /* cp_table entries : child followed by parent APid:CAid APid:PAid AVid:AYid AYid:CAid CJid:JPid CJid:CSid CSid:UTid CSid:PAid FUid:CFid FUid:SUid FVid:FYid FYid:CFid OUid:JPid OUid:SUid PAid:HOid ROid:HOid SSid:TTid SSid:HOid SUid:PAid SUid:ROid UTid:CUid UTid:HOid */ #define APptr->HOid APpptr->PApptr->HOpptr->HOid #define APptr->hstyle APpptr->PApptr->HOpptr->hstyle #define APptr->nfloors APpptr->PApptr->HOpptr->nfloors #define APptr->nrooms APpptr->PApptr->HOpptr->nrooms #define APptr->hlength APpptr->PApptr->HOpptr->hlength #define APptr->hwidth APpptr->PApptr->HOpptr->hwidth #define AVptr->CAid AVpptr->AYpptr->CApptr->CAid #define AVptr->atype AVpptr->AYpptr->CApptr->atype #define AVptr->astyle AVpptr->AYpptr->CApptr->astyle #define AVptr->adim1 AVpptr->AYpptr->CApptr->adim1 #define AVptr->adim2 AVpptr->AYpptr->CApptr->adim2 #define CJptr->CUid CJpptr->CSpptr->UTpptr->CUpptr->CUid #define CJptr->utype CJpptr->CSpptr->UTpptr->CUpptr->utype #define CJptr->uclass CJpptr->CSpptr->UTpptr->CUpptr->uclass #define CJptr->ucolor CJpptr->CSpptr->UTpptr->CUpptr->ucolor #define CJptr->HOid CJpptr->CSpptr->PApptr->HOpptr->HOid #define CJptr->hstyle CJpptr->CSpptr->PApptr->HOpptr->hstyle #define CJptr->nfloors CJpptr->CSpptr->PApptr->HOpptr->nfloors #define CJptr->nrooms CJpptr->CSpptr->PApptr->HOpptr->nrooms #define CJptr->hlength CJpptr->CSpptr->PApptr->HOpptr->hlength #define CJptr->hwidth CJpptr->CSpptr->PApptr->HOpptr->hwidth #define CJptr->HOid CJpptr->CSpptr->UTpptr->HOpptr->HOid #define CJptr->hstyle CJpptr->CSpptr->UTpptr->HOpptr->hstyle #define CJptr->nfloors CJpptr->CSpptr->UTpptr->HOpptr->nfloors #define CJptr->nrooms CJpptr->CSpptr->UTpptr->HOpptr->nrooms #define CJptr->hlength CJpptr->CSpptr->UTpptr->HOpptr->hlength #define CJptr->hwidth CJpptr->CSpptr->UTpptr->HOpptr->hwidth #define CJptr->PAid CJpptr->CSpptr->PApptr->PAid #define CJptr->HOid CJpptr->CSpptr->PApptr->HOid #define CJptr->porient CJpptr->CSpptr->PApptr->porient #define CJptr->pdim1 CJpptr->CSpptr->PApptr->pdim1 #define CJptr->pdim2 CJpptr->CSpptr->PApptr->pdim2 #define CJptr->px CJpptr->CSpptr->PApptr->px #define CJptr->py CJpptr->CSpptr->PApptr->py #define CJptr->UTid CJpptr->CSpptr->UTpptr->UTid #define CJptr->HOid CJpptr->CSpptr->UTpptr->HOid #define CJptr->CUid CJpptr->CSpptr->UTpptr->CUid #define CSptr->CUid CSpptr->UTpptr->CUpptr->CUid #define CSptr->utype CSpptr->UTpptr->CUpptr->utype #define CSptr->uclass CSpptr->UTpptr->CUpptr->uclass #define CSptr->ucolor CSpptr->UTpptr->CUpptr->ucolor #define CSptr->HOid CSpptr->PApptr->HOpptr->HOid #define CSptr->hstyle CSpptr->PApptr->HOpptr->hstyle #define CSptr->nfloors CSpptr->PApptr->HOpptr->nfloors #define CSptr->nrooms CSpptr->PApptr->HOpptr->nrooms #define CSptr->hlength CSpptr->PApptr->HOpptr->hlength #define CSptr->hwidth CSpptr->PApptr->HOpptr->hwidth #define CSptr->HOid CSpptr->UTpptr->HOpptr->HOid #define CSptr->hstyle CSpptr->UTpptr->HOpptr->hstyle #define CSptr->nfloors CSpptr->UTpptr->HOpptr->nfloors #define CSptr->nrooms CSpptr->UTpptr->HOpptr->nrooms #define CSptr->hlength CSpptr->UTpptr->HOpptr->hlength #define CSptr->hwidth CSpptr->UTpptr->HOpptr->hwidth #define FUptr->HOid FUpptr->SUpptr->ROpptr->HOpptr->HOid #define FUptr->hstyle FUpptr->SUpptr->ROpptr->HOpptr->hstyle #define FUptr->nfloors FUpptr->SUpptr->ROpptr->HOpptr->nfloors #define FUptr->nrooms FUpptr->SUpptr->ROpptr->HOpptr->nrooms #define FUptr->hlength FUpptr->SUpptr->ROpptr->HOpptr->hlength #define FUptr->hwidth FUpptr->SUpptr->ROpptr->HOpptr->hwidth #define FUptr->HOid FUpptr->SUpptr->PApptr->HOpptr->HOid #define FUptr->hstyle FUpptr->SUpptr->PApptr->HOpptr->hstyle #define FUptr->nfloors FUpptr->SUpptr->PApptr->HOpptr->nfloors #define FUptr->nrooms FUpptr->SUpptr->PApptr->HOpptr->nrooms #define FUptr->hlength FUpptr->SUpptr->PApptr->HOpptr->hlength #define FUptr->hwidth FUpptr->SUpptr->PApptr->HOpptr->hwidth #define FUptr->PAid FUpptr->SUpptr->PApptr->PAid #define FUptr->HOid FUpptr->SUpptr->PApptr->HOid #define FUptr->porient FUpptr->SUpptr->PApptr->porient #define FUptr->pdim1 FUpptr->SUpptr->PApptr->pdim1 #define FUptr->pdim2 FUpptr->SUpptr->PApptr->pdim2 #define FUptr->px FUpptr->SUpptr->PApptr->px #define FUptr->py FUpptr->SUpptr->PApptr->py #define FUptr->ROid FUpptr->SUpptr->ROpptr->ROid #define FUptr->HOid FUpptr->SUpptr->ROpptr->HOid #define FUptr->rtype FUpptr->SUpptr->ROpptr->rtype #define FUptr->rwidth FUpptr->SUpptr->ROpptr->rwidth #define FUptr->rdepth FUpptr->SUpptr->ROpptr->rdepth #define FUptr->rx FUpptr->SUpptr->ROpptr->rx #define FUptr->ry FUpptr->SUpptr->ROpptr->ry #define FVptr->CFid FVpptr->FYpptr->CFpptr->CFid #define FVptr->ftype FVpptr->FYpptr->CFpptr->ftype #define FVptr->fstyle FVpptr->FYpptr->CFpptr->fstyle #define FVptr->fdim1 FVpptr->FYpptr->CFpptr->fdim1 #define FVptr->fdim2 FVpptr->FYpptr->CFpptr->fdim2 #define FVptr->fprice FVpptr->FYpptr->CFpptr->fprice #define OUptr->HOid OUpptr->SUpptr->ROpptr->HOpptr->HOid #define OUptr->hstyle OUpptr->SUpptr->ROpptr->HOpptr->hstyle #define OUptr->nfloors OUpptr->SUpptr->ROpptr->HOpptr->nfloors #define OUptr->nrooms OUpptr->SUpptr->ROpptr->HOpptr->nrooms #define OUptr->hlength OUpptr->SUpptr->ROpptr->HOpptr->hlength #define OUptr->hwidth OUpptr->SUpptr->ROpptr->HOpptr->hwidth #define OUptr->HOid OUpptr->SUpptr->PApptr->HOpptr->HOid #define OUptr->hstyle OUpptr->SUpptr->PApptr->HOpptr->hstyle #define OUptr->nfloors OUpptr->SUpptr->PApptr->HOpptr->nfloors #define OUptr->nrooms OUpptr->SUpptr->PApptr->HOpptr->nrooms #define OUptr->hlength OUpptr->SUpptr->PApptr->HOpptr->hlength #define OUptr->hwidth OUpptr->SUpptr->PApptr->HOpptr->hwidth #define OUptr->PAid OUpptr->SUpptr->PApptr->PAid #define OUptr->HOid OUpptr->SUpptr->PApptr->HOid #define OUptr->porient OUpptr->SUpptr->PApptr->porient #define OUptr->pdim1 OUpptr->SUpptr->PApptr->pdim1 #define OUptr->pdim2 OUpptr->SUpptr->PApptr->pdim2 #define OUptr->px OUpptr->SUpptr->PApptr->px #define OUptr->py OUpptr->SUpptr->PApptr->py #define OUptr->ROid OUpptr->SUpptr->ROpptr->ROid #define OUptr->HOid OUpptr->SUpptr->ROpptr->HOid #define OUptr->rtype OUpptr->SUpptr->ROpptr->rtype #define OUptr->rwidth OUpptr->SUpptr->ROpptr->rwidth #define OUptr->rdepth OUpptr->SUpptr->ROpptr->rdepth #define OUptr->rx OUpptr->SUpptr->ROpptr->rx #define OUptr->ry OUpptr->SUpptr->ROpptr->ry #define SUptr->HOid SUpptr->ROpptr->HOpptr->HOid #define SUptr->hstyle SUpptr->ROpptr->HOpptr->hstyle #define SUptr->nfloors SUpptr->ROpptr->HOpptr->nfloors #define SUptr->nrooms SUpptr->ROpptr->HOpptr->nrooms #define SUptr->hlength SUpptr->ROpptr->HOpptr->hlength #define SUptr->hwidth SUpptr->ROpptr->HOpptr->hwidth #define SUptr->HOid SUpptr->PApptr->HOpptr->HOid #define SUptr->hstyle SUpptr->PApptr->HOpptr->hstyle #define SUptr->nfloors SUpptr->PApptr->HOpptr->nfloors #define SUptr->nrooms SUpptr->PApptr->HOpptr->nrooms #define SUptr->hlength SUpptr->PApptr->HOpptr->hlength #define SUptr->hwidth SUpptr->PApptr->HOpptr->hwidth /* hdb_schema.txt : schema for a house database */ /* in project$disk:[swe.88su523.kwu] as of 17-AUG-88 20:00 */ /* integrates interior decorator and building contractor views */ /* tables are in top-down order but may be sorted alphabetically later */ /* an accompanying file in project$disk:[swe.88su523.kwu]hdb_schema.hlp will */ /* contain notes for added understanding and are referenced by "see n#" */ struct AP /*apertures are openings in one of both sides of a partition*/ { char APid[9] ; /*unique id of this aperture in db*/ char PAid[9] ; /*unique id of assoc. partition*/ char CAid[9] ; /*unique id of assoc. catalog*/ float adis1 ; /*(E-W)displacement for (n-s)see n1*/ float adis2 ; /*(N-S)displacement for (u-d)see n2*/ char acolor[13] ; /*color name of the aperture*/ struct CA *CAid_pptr ; union { struct AP *ptr0 ; struct CA *ptr1 ; } *CAid_fpptr ; int CAid_fpptr_border_flag ; union { struct AP *ptr0 ; struct CA *ptr1 ; } *CAid_bpptr ; int CAid_bpptr_border_flag ; struct PA *PAid_pptr ; union { struct AP *ptr0 ; struct PA *ptr1 ; } *PAid_fpptr ; int PAid_fpptr_border_flag ; union { struct AP *ptr0 ; struct PA *ptr1 ; } *PAid_bpptr ; int PAid_bpptr_border_flag ; struct AP *prev_ptr ; struct AP *next_ptr ; } *AP = NULL , *APcurr = NULL , *APtemp = NULL ; struct AV /*vertices of aperture polygons*/ { char AVid[9] ; /*unique id of aperture vertex*/ char AYid[9] ; /*assoc. aperture polygon id*/ float av1 ; /*from LL in dir. of adim1 in CA*/ float av2 ; /*from LL in dir. of adim2 in CA*/ float av3 ; /*from LL in dir. of normal to poly*/ float avorder ; /*CCw order # around poly (1-nvert)*/ struct AY *AYid_pptr ; union { struct AV *ptr0 ; struct AY *ptr1 ; } *AYid_fpptr ; int AYid_fpptr_border_flag ; union { struct AV *ptr0 ; struct AY *ptr1 ; } *AYid_bpptr ; int AYid_bpptr_border_flag ; struct AV *prev_ptr ; struct AV *next_ptr ; } *AV = NULL , *AVcurr = NULL , *AVtemp = NULL ; struct AY /*polygons for apertures*/ { char AYid[9] ; /*unique id of aperture_polygon*/ char CAid[9] ; /*assoc. id of aperture catalog id*/ char anvert[9] ; /*number of vertices in polygon*/ struct CA *CAid_pptr ; union { struct AY *ptr0 ; struct CA *ptr1 ; } *CAid_fpptr ; int CAid_fpptr_border_flag ; union { struct AY *ptr0 ; struct CA *ptr1 ; } *CAid_bpptr ; int CAid_bpptr_border_flag ; struct AV *AVid_fcptr ; struct AV *AVid_bcptr ; struct AY *prev_ptr ; struct AY *next_ptr ; } *AY = NULL , *AYcurr = NULL , *AYtemp = NULL ; struct CA /*catalog of apertures*/ { char CAid[9] ; /*unique id of catalog_aperture*/ char atype[9] ; /*type (door-window)*/ char astyle[9] ; /*style(ex. picture/double window*/ float adim1 ; /*measurement across from LL pt*/ float adim2 ; /*measurement up from LL pt*/ struct AY *AYid_fcptr ; struct AY *AYid_bcptr ; struct AP *APid_fcptr ; struct AP *APid_bcptr ; struct CA *prev_ptr ; struct CA *next_ptr ; } *CA = NULL , *CAcurr = NULL , *CAtemp = NULL ; struct CF /*catalog of furnishings*/ { char CFid[9] ; /*unique id of catalog_furnishing*/ char ftype[9] ; /*type(rug, mirror,picture)*/ char fstyle[9] ; /*style(rug ex:shag,rag,oriental)*/ float fdim1 ; /*measurement across from LL pt*/ float fdim2 ; /*measurement up from LL pt*/ float fprice ; /*price of the furniture*/ struct FY *FYid_fcptr ; struct FY *FYid_bcptr ; struct FU *FUid_fcptr ; struct FU *FUid_bcptr ; struct CF *prev_ptr ; struct CF *next_ptr ; } *CF = NULL , *CFcurr = NULL , *CFtemp = NULL ; struct CJ /*conduit joint point*/ { char CJid[9] ; /*unique id of conduit joint point*/ char CSid[9] ; /*unique id of conduit segment*/ char JPid[9] ; /*unique id of jointpoint*/ struct JP *JPid_pptr ; union { struct CJ *ptr0 ; struct JP *ptr1 ; } *JPid_fpptr ; int JPid_fpptr_border_flag ; union { struct CJ *ptr0 ; struct JP *ptr1 ; } *JPid_bpptr ; int JPid_bpptr_border_flag ; struct CS *CSid_pptr ; union { struct CJ *ptr0 ; struct CS *ptr1 ; } *CSid_fpptr ; int CSid_fpptr_border_flag ; union { struct CJ *ptr0 ; struct CS *ptr1 ; } *CSid_bpptr ; int CSid_bpptr_border_flag ; struct CJ *prev_ptr ; struct CJ *next_ptr ; } *CJ = NULL , *CJcurr = NULL , *CJtemp = NULL ; struct CS /*conduit segment of utility*/ { char CSid[9] ; /*unique id of conduit segment*/ char PAid[9] ; /*unique id of assoc. partition*/ char UTid[9] ; /*unique id of assoc. utility*/ struct UT *UTid_pptr ; union { struct CS *ptr0 ; struct UT *ptr1 ; } *UTid_fpptr ; int UTid_fpptr_border_flag ; union { struct CS *ptr0 ; struct UT *ptr1 ; } *UTid_bpptr ; int UTid_bpptr_border_flag ; struct PA *PAid_pptr ; union { struct CS *ptr0 ; struct PA *ptr1 ; } *PAid_fpptr ; int PAid_fpptr_border_flag ; union { struct CS *ptr0 ; struct PA *ptr1 ; } *PAid_bpptr ; int PAid_bpptr_border_flag ; struct CJ *CJid_fcptr ; struct CJ *CJid_bcptr ; struct CS *prev_ptr ; struct CS *next_ptr ; } *CS = NULL , *CScurr = NULL , *CStemp = NULL ; struct CU /*catalog of utility*/ { char CUid[9] ; /*unique id of catalogutility*/ char utype[13] ; /*type(heat, electricity,etc)*/ char uclass[13] ; /*class(gas, oil, electric)*/ char ucolor[13] ; /*color name*/ struct UT *UTid_fcptr ; struct UT *UTid_bcptr ; struct CU *prev_ptr ; struct CU *next_ptr ; } *CU = NULL , *CUcurr = NULL , *CUtemp = NULL ; struct FU /*furnishing relative to surfaces*/ { char FUid[9] ; /*unique id of this furnishing in db*/ char SUid[9] ; /*unique id of assoc. surface*/ char CFid[9] ; /*unique id of assoc. catalog*/ float fdis1 ; /*(E-W)measurement for (n-s) see n1*/ float fdis2 ; /*(N-S)measurement for (u-d) see n2*/ char fcolor[13] ; /*furnishing color */ struct CF *CFid_pptr ; union { struct FU *ptr0 ; struct CF *ptr1 ; } *CFid_fpptr ; int CFid_fpptr_border_flag ; union { struct FU *ptr0 ; struct CF *ptr1 ; } *CFid_bpptr ; int CFid_bpptr_border_flag ; struct SU *SUid_pptr ; union { struct FU *ptr0 ; struct SU *ptr1 ; } *SUid_fpptr ; int SUid_fpptr_border_flag ; union { struct FU *ptr0 ; struct SU *ptr1 ; } *SUid_bpptr ; int SUid_bpptr_border_flag ; struct FU *prev_ptr ; struct FU *next_ptr ; } *FU = NULL , *FUcurr = NULL , *FUtemp = NULL ; struct FV /*vertices of furnishing polygons*/ { char FVid[9] ; /*unique id of furnishing vertex*/ char FYid[9] ; /*assoc. furnishing polygon id*/ float fv1 ; /*from LL in dir. of fdim1 in CF*/ float fv2 ; /*from LL in dir. of fdim2 in CF*/ float fv3 ; /*from LL in dir. of normal to poly*/ float fvorder ; /*CCw order # around poly (1-nvert)*/ struct FY *FYid_pptr ; union { struct FV *ptr0 ; struct FY *ptr1 ; } *FYid_fpptr ; int FYid_fpptr_border_flag ; union { struct FV *ptr0 ; struct FY *ptr1 ; } *FYid_bpptr ; int FYid_bpptr_border_flag ; struct FV *prev_ptr ; struct FV *next_ptr ; } *FV = NULL , *FVcurr = NULL , *FVtemp = NULL ; struct FY /*polygons for furnishings*/ { char FYid[9] ; /*unique id of furnishing_polygon*/ char CFid[9] ; /*assoc. id of furn. catalog id*/ char fnvert[9] ; /*number of vertices in polygon*/ struct CF *CFid_pptr ; union { struct FY *ptr0 ; struct CF *ptr1 ; } *CFid_fpptr ; int CFid_fpptr_border_flag ; union { struct FY *ptr0 ; struct CF *ptr1 ; } *CFid_bpptr ; int CFid_bpptr_border_flag ; struct FV *FVid_fcptr ; struct FV *FVid_bcptr ; struct FY *prev_ptr ; struct FY *next_ptr ; } *FY = NULL , *FYcurr = NULL , *FYtemp = NULL ; struct HO /*list of houses with ids, styles, number of floors and rooms*/ { char HOid[9] ; /*unique id of one house in the db*/ char hstyle[13] ; /*style (colonial-cape-ranch)*/ int nfloors ; /*number of floors in this house*/ int nrooms ; /*number of rooms in this house*/ float hlength ; /*overall length(ft) of this house*/ float hwidth ; /*overall width(ft) of this house*/ struct UT *UTid_fcptr ; struct UT *UTid_bcptr ; struct SS *SSid_fcptr ; struct SS *SSid_bcptr ; struct RO *ROid_fcptr ; struct RO *ROid_bcptr ; struct PA *PAid_fcptr ; struct PA *PAid_bcptr ; struct HO *prev_ptr ; struct HO *next_ptr ; } *HO = NULL , *HOcurr = NULL , *HOtemp = NULL ; struct JP /*the joint point of two conduit segment*/ { char JPid[9] ; /*unique id of joint_point*/ float jx ; /*joint point world x coordinate*/ float jy ; /*joint point world y coordinate*/ float jz ; /*joint point world z coordinate*/ struct OU *OUid_fcptr ; struct OU *OUid_bcptr ; struct CJ *CJid_fcptr ; struct CJ *CJid_bcptr ; struct JP *prev_ptr ; struct JP *next_ptr ; } *JP = NULL , *JPcurr = NULL , *JPtemp = NULL ; struct OU /* the outlet of the conduit*/ { char OUid[9] ; /*unique id of outlet*/ char SUid[9] ; /*unique id of assoc. surface*/ char JPid[9] ; /*unique id of assoc. joint point*/ float odim1 ; /*measurement across from LL pt*/ float odim2 ; /*measurement up from LL pt*/ struct JP *JPid_pptr ; union { struct OU *ptr0 ; struct JP *ptr1 ; } *JPid_fpptr ; int JPid_fpptr_border_flag ; union { struct OU *ptr0 ; struct JP *ptr1 ; } *JPid_bpptr ; int JPid_bpptr_border_flag ; struct SU *SUid_pptr ; union { struct OU *ptr0 ; struct SU *ptr1 ; } *SUid_fpptr ; int SUid_fpptr_border_flag ; union { struct OU *ptr0 ; struct SU *ptr1 ; } *SUid_bpptr ; int SUid_bpptr_border_flag ; struct OU *prev_ptr ; struct OU *next_ptr ; } *OU = NULL , *OUcurr = NULL , *OUtemp = NULL ; struct PA /*partition separating rooms from each other and outside*/ { char PAid[9] ; /*unique id of this partition in db*/ char HOid[9] ; /*id of house containing partition*/ char porient[2] ; /*N-S-E-W-U-D normal to surface*/ float pdim1 ; /*(E-W)measurement for (n-s)see n3*/ float pdim2 ; /*(N-S)measurement for (u-d)see n4*/ float px ; /*x (E-W) coord of SW corner of PA*/ float py ; /*y (N-S) coord of SW corner of PA*/ struct HO *HOid_pptr ; union { struct PA *ptr0 ; struct HO *ptr1 ; } *HOid_fpptr ; int HOid_fpptr_border_flag ; union { struct PA *ptr0 ; struct HO *ptr1 ; } *HOid_bpptr ; int HOid_bpptr_border_flag ; struct SU *SUid_fcptr ; struct SU *SUid_bcptr ; struct CS *CSid_fcptr ; struct CS *CSid_bcptr ; struct AP *APid_fcptr ; struct AP *APid_bcptr ; struct PA *prev_ptr ; struct PA *next_ptr ; } *PA = NULL , *PAcurr = NULL , *PAtemp = NULL ; struct RO /*list of rooms in each house with relative position and dimension*/ { char ROid[9] ; /*uniue id of room in db*/ char HOid[9] ; /*unique id of house containing room*/ char rtype[13] ; /*type of room (kitchen, bedroom)*/ float rwidth ; /*width of room in E-W direction*/ float rdepth ; /*depth of room in N-S direction*/ float rx ; /*x (E-W) world coord.of SW corner*/ float ry ; /*y (N-S) world coord.of SW corner*/ struct HO *HOid_pptr ; union { struct RO *ptr0 ; struct HO *ptr1 ; } *HOid_fpptr ; int HOid_fpptr_border_flag ; union { struct RO *ptr0 ; struct HO *ptr1 ; } *HOid_bpptr ; int HOid_bpptr_border_flag ; struct SU *SUid_fcptr ; struct SU *SUid_bcptr ; struct RO *prev_ptr ; struct RO *next_ptr ; } *RO = NULL , *ROcurr = NULL , *ROtemp = NULL ; struct SS /*statistical summary of id count-min-max vals per table and house*/ { char SSid[9] ; /*unique id of row in stats table*/ char HOid[9] ; /*identifies house for this line*/ char TTid[9] ; /*id of table_type entry in shcema*/ char Tabbrev[3] ; /*2 char abbrev of this table type*/ int rcount ; /*number of table rows for house*/ char minrowid[9] ; /*min value of row_id (id_format)*/ char maxrowid[9] ; /*max value of row_id */ struct TT *TTid_pptr ; union { struct SS *ptr0 ; struct TT *ptr1 ; } *TTid_fpptr ; int TTid_fpptr_border_flag ; union { struct SS *ptr0 ; struct TT *ptr1 ; } *TTid_bpptr ; int TTid_bpptr_border_flag ; struct HO *HOid_pptr ; union { struct SS *ptr0 ; struct HO *ptr1 ; } *HOid_fpptr ; int HOid_fpptr_border_flag ; union { struct SS *ptr0 ; struct HO *ptr1 ; } *HOid_bpptr ; int HOid_bpptr_border_flag ; struct SS *prev_ptr ; struct SS *next_ptr ; } *SS = NULL , *SScurr = NULL , *SStemp = NULL ; struct SU /*surfaces relate partitions to rooms(min 6-room, 2-partion)*/ { char SUid[9] ; /*unique id of this surface in db*/ char ROid[9] ; /*unique id of adj. room(exactly 1)*/ char PAid[9] ; /*unique id of adj. partition(1)*/ char scolor[13] ; /*color name of the surface*/ struct PA *PAid_pptr ; union { struct SU *ptr0 ; struct PA *ptr1 ; } *PAid_fpptr ; int PAid_fpptr_border_flag ; union { struct SU *ptr0 ; struct PA *ptr1 ; } *PAid_bpptr ; int PAid_bpptr_border_flag ; struct RO *ROid_pptr ; union { struct SU *ptr0 ; struct RO *ptr1 ; } *ROid_fpptr ; int ROid_fpptr_border_flag ; union { struct SU *ptr0 ; struct RO *ptr1 ; } *ROid_bpptr ; int ROid_bpptr_border_flag ; struct OU *OUid_fcptr ; struct OU *OUid_bcptr ; struct FU *FUid_fcptr ; struct FU *FUid_bcptr ; struct SU *prev_ptr ; struct SU *next_ptr ; } *SU = NULL , *SUcurr = NULL , *SUtemp = NULL ; struct TT /*statistical summary of id count-min-max vals per table and house*/ { char TTid[9] ; /*unique id of row in stats table*/ char TTabbrev[3] ; /*2 char abbrev of this table type*/ int TTcount ; /*number of table rows for house*/ char TTnrowid[9] ; /*min value of row_id (id_format)*/ char TTxrowid[9] ; /*max value of row_id */ struct SS *SSid_fcptr ; struct SS *SSid_bcptr ; struct TT *prev_ptr ; struct TT *next_ptr ; } *TT = NULL , *TTcurr = NULL , *TTtemp = NULL ; struct UT /*utility view*/ { char UTid[9] ; /*unique id of the utility*/ char HOid[9] ; /*unique id of the house*/ char CUid[9] ; /*unique id of the catalog_utility*/ struct CU *CUid_pptr ; union { struct UT *ptr0 ; struct CU *ptr1 ; } *CUid_fpptr ; int CUid_fpptr_border_flag ; union { struct UT *ptr0 ; struct CU *ptr1 ; } *CUid_bpptr ; int CUid_bpptr_border_flag ; struct HO *HOid_pptr ; union { struct UT *ptr0 ; struct HO *ptr1 ; } *HOid_fpptr ; int HOid_fpptr_border_flag ; union { struct UT *ptr0 ; struct HO *ptr1 ; } *HOid_bpptr ; int HOid_bpptr_border_flag ; struct CS *CSid_fcptr ; struct CS *CSid_bcptr ; struct UT *prev_ptr ; struct UT *next_ptr ; } *UT = NULL , *UTcurr = NULL , *UTtemp = NULL ;