/*============================================================================= Name: dbdict.h Abs: Public prototypes for dbdict.c Reference LCLS Controls | Facilities |SLC-Aware IOC | Database Service (DBS) Design Document Reference RMX_DBS dbmain.c Auth: 1 DEC 2004, drogind created Rev: 17 DEC-2004, drogind modified prototype code to production standards -----------------------------------------------------------------------------*/ #include "copyright_SLAC.h" /*----------------------------------------------------------------------------- Mod: (newest to oldest) DD-MMM-YYYY, My Name: Changed such and such to so and so. etc. etc. DD-MMM-YYYY, Your Name: More changes ... The ordering of the revision history should be such that the NEWEST changes are at the HEAD of the list. =============================================================================*/ #ifndef INCdbdictH #define INCdbdictH #include "dbhash.h" #include "ellLib.h" #include "dbST0.h" #ifdef __cplusplus extern "C" { #endif typedef struct { char name[12]; } dbdictNameTriplet_ts; typedef struct { char name[4]; } dbdictNameSgl_ts; #define SZ_NAME_SGL sizeof(dbdictNameSgl_ts) /* size of primary name in hash tbl */ /* size of unit name in hash tbl */ /* size of secn name in hash tbl */ #define SZ_NAME_PUS sizeof(dbdictNameTriplet_ts)/* size of prim unit secn name in hash tbl */ #define WSZ_NAME_SGL SZ_NAME_SGL/2 typedef struct { ELLLIST listUnits; /* linked list head for units */ }dbdictP_ts; typedef struct { short supn; /* supertype number */ short count; /* word count */ unsigned long sptr; /* word offset into supn block */ short width; /* data width */ char format; /* (I,A,R,Z,S,T)*/ }dbdictPUS_ts; typedef struct { ELLNODE node; /* node */ ELLLIST listSecns; /* linked list head for secondaries */ dbdictNameSgl_ts *name; /* ASCII unit name */ unsigned short unit; /* integer unit */ }dbdictU_ts; typedef struct { ELLNODE node; dbhEntry_ts *dbdictEntry; dbdictNameSgl_ts *name; }dbdictS_ts; void dbdictInitFreeLists ( void); void dbdictDelFreeLists ( void); dbhEntry_ts * dbdictInsP(const char *prim_p, const epicsBoolean hasunits ); vmsstat_t dbdictInsAllUnits (const dbdictP_ts * unitList_ps,const dbST0header_ts * dbunits_ps); vmsstat_t dbdictInsSecnInAllUnits ( const dbdictP_ts * unitList_ps, const dbST0header_ts * dbunits_ps, const char * prim_p, const char * secn_p, const dbST0header_ts * dblist_ps, const short width, const char fmt, const short supn, dbST0header_ts **const dbdata_pp); #ifdef __cplusplus } #endif #endif /*INCdbdictH*/