/********************************************************************************************************************************/ /* Created: 9-Mar-2021 22:28:04 by OpenVMS SDL EV3-3 */ /* Source: 09-MAR-2021 22:28:01 $1$DGA8085:[STARLET_H.SRC]RMSUSR.SDI;1 */ /********************************************************************************************************************************/ /*** MODULE $XABKEYDEF ***/ #ifndef __XABKEYDEF_LOADED #define __XABKEYDEF_LOADED 1 #pragma __nostandard /* This file uses non-ANSI-Standard features */ #pragma __member_alignment __save #pragma __nomember_alignment #ifdef __INITIAL_POINTER_SIZE /* Defined whenever ptr size pragmas supported */ #pragma __required_pointer_size __save /* Save the previously-defined required ptr size */ #pragma __required_pointer_size __short /* And set ptr size default to 32-bit pointers */ #endif #ifdef __cplusplus extern "C" { #define __unknown_params ... #define __optional_params ... #else #define __unknown_params #define __optional_params ... #endif #ifndef __struct #if !defined(__VAXC) #define __struct struct #else #define __struct variant_struct #endif #endif #ifndef __union #if !defined(__VAXC) #define __union union #else #define __union variant_union #endif #endif /* */ /* key definition xab field definitions */ /* $xabkeydef */ /* */ #define XAB$C_KEY 21 /* xabkey id code */ #define XAB$M_DUP 0x1 #define XAB$M_CHG 0x2 #define XAB$M_NUL 0x4 #define XAB$M_IDX_NCMPR 0x8 #define XAB$M_KEY_NCMPR 0x40 #define XAB$M_DAT_NCMPR 0x80 #define XAB$C_STG 0 /* string */ #define XAB$C_IN2 1 /* signed 15 bit integer (2 bytes) */ #define XAB$C_BN2 2 /* 2 byte binary */ #define XAB$C_IN4 3 /* signed 31 bit integer (4 bytes) */ #define XAB$C_BN4 4 /* 4 byte binary */ #define XAB$C_PAC 5 /* packed decimal (1-16 bytes) */ #define XAB$C_IN8 6 /* signed 63 bit integer (4 bytes) */ #define XAB$C_BN8 7 /* 8 byte binary */ #define XAB$C_COL 8 /* collated */ #define XAB$C_MAX_ASCEND 8 /* maximum ascending type */ #define XAB$C_DSTG 32 /* descending string */ #define XAB$C_DIN2 33 /* " signed word */ #define XAB$C_DBN2 34 /* " unsigned word */ #define XAB$C_DIN4 35 /* " signed longword */ #define XAB$C_DBN4 36 /* " unsigned longword */ #define XAB$C_DPAC 37 /* " packed decimal */ #define XAB$C_DIN8 38 /* " signed quadword */ #define XAB$C_DBN8 39 /* " unsigned quadword */ #define XAB$C_DCOL 40 /* " collated */ #define XAB$C_MAXDTP 40 /* max. legal data type */ #define XAB$K_KEYLEN_V2 64 /* old xabkey length */ #define XAB$C_KEYLEN_V2 64 /* old xabkey length */ /* */ #define XAB$C_PRG3 3 /* Prologue version three */ #define XAB$C_PRG2 2 /* Prologue version two */ #define XAB$C_PRG1 1 /* Prologue versoin one */ #define XAB$K_KEYLEN_V4 76 /* xabkey length until V5 */ #define XAB$C_KEYLEN_V4 76 /* xabkey length until V5 */ #ifdef __NEW_STARLET #if !defined(__NOBASEALIGN_SUPPORT) && !defined(__cplusplus) /* If using pre DECC V4.0 or C++ */ #pragma __nomember_alignment __longword #else #pragma __nomember_alignment #endif typedef struct _xabkeydef { #pragma __nomember_alignment unsigned char xab$b_cod; /* xab id code */ unsigned char xab$b_bln; /* block length */ short int xabkeydef$$_fill_1; /* (spare) */ void *xab$l_nxt; /* xab chain link */ /* */ /* the field layout of the key xab is such that it matchs as */ /* closely as possible the layout of a key decriptor in the */ /* index file prologue. this is so the contents may be moved */ /* between the two structures as efficiently as possible. */ /* */ unsigned char xab$b_ian; /* index level area number */ unsigned char xab$b_lan; /* lowest index level area number */ unsigned char xab$b_dan; /* data level area number */ unsigned char xab$b_lvl; /* level of root bucket */ unsigned char xab$b_ibs; /* size of index buckets in virtual blocks */ unsigned char xab$b_dbs; /* size of data buckets in virtual blocks */ unsigned int xab$l_rvb; /* root bucket start vbn */ __union { unsigned char xab$b_flg; /* key option flags */ __struct { unsigned xab$v_dup : 1; /* duplicate key values allowed */ unsigned xab$v_chg : 1; /* alt key only --key field may change on update */ unsigned xab$v_nul : 1; /* alt key only --null key value enable */ unsigned xab$v_idx_ncmpr : 1; /* indicate index records for given key are not compressed */ unsigned xabkeydef$$_fill_5 : 2; /* spare */ unsigned xab$v_key_ncmpr : 1; /* indicates key is not compressed in data record */ unsigned xab$v_fill_14_ : 1; } xab$r_flg_bits0; __struct { unsigned xabkeydef$$_fill_6 : 1; /* space over dup */ unsigned xabkeydef$$_fill_7 : 2; /* spare */ unsigned xabkeydef$$_fill_8 : 1; /* space over idx_ncmpr */ unsigned xabkeydef$$_fill_9 : 2; /* spare */ unsigned xabkeydef$$_fill_10 : 1; /* space over key_ncmpr */ unsigned xab$v_dat_ncmpr : 1; /* data record is not compressed */ } xab$r_flg_bits1; } xab$r_flg_overlay; unsigned char xab$b_dtp; /* key field data type */ unsigned char xab$b_nsg; /* number of key segments */ unsigned char xab$b_nul; /* nul key character */ unsigned char xab$b_tks; /* total key field size (bytes) */ unsigned char xab$b_ref; /* key of reference (0=prim key, */ /* 1-254 = alternate keys) */ unsigned short int xab$w_mrl; /* minimun record length to contain key field */ unsigned short int xab$w_ifl; /* index bucket fill size (bytes) */ unsigned short int xab$w_dfl; /* data bucket fil size (bytes) */ __union { unsigned short int xab$w_pos [8]; /* key field record offset positions */ __struct { unsigned short int xab$w_pos0; /* segment 0 */ unsigned short int xab$w_pos1; /* segment 1 */ unsigned short int xab$w_pos2; /* segment 2 */ unsigned short int xab$w_pos3; /* segment 3 */ unsigned short int xab$w_pos4; /* segment 4 */ unsigned short int xab$w_pos5; /* segment 5 */ unsigned short int xab$w_pos6; /* segment 6 */ unsigned short int xab$w_pos7; /* segment 7 */ } xab$r_pos_fields; } xab$r_pos_overlay; __union { unsigned char xab$b_siz [8]; /* key field segment sizes */ __struct { unsigned char xab$b_siz0; /* segment 0 */ unsigned char xab$b_siz1; /* segment 1 */ unsigned char xab$b_siz2; /* segment 2 */ unsigned char xab$b_siz3; /* segment 3 */ unsigned char xab$b_siz4; /* segment 4 */ unsigned char xab$b_siz5; /* segment 5 */ unsigned char xab$b_siz6; /* segment 6 */ unsigned char xab$b_siz7; /* segment 7 */ } xab$r_siz_fields; } xab$r_siz_overlay; short int xabkeydef$$_fill_11; /* spare */ /* */ /* the positions of the above fields are dictated by the key descriptor */ /* record layout in the index file prologue. */ /* */ char *xab$l_knm; /* pointer to 32 character key name buffer */ unsigned int xab$l_dvb; /* first data bucket start vbn */ /* Additions for prologue 3 files */ /* */ __union { unsigned char xab$b_typ [8]; /* key field segment types */ __struct { unsigned char xab$b_typ0; /* segment 0 */ unsigned char xab$b_typ1; /* segment 1 */ unsigned char xab$b_typ2; /* segment 2 */ unsigned char xab$b_typ3; /* segment 3 */ unsigned char xab$b_typ4; /* segment 4 */ unsigned char xab$b_typ5; /* segment 5 */ unsigned char xab$b_typ6; /* segment 6 */ unsigned char xab$b_typ7; /* segment 7 */ } xab$r_typ_fields; } xab$r_typ_overlay; unsigned char xab$b_prolog; /* indicate prologue version desired (primary key only) */ char xabkeydef$$_fill_12; /* spare */ short int xabkeydef$$_fill_13; /* spare */ void *xab$l_coltbl; /* address of collate table */ unsigned int xab$l_colsiz; /* size of collate table */ char *xab$l_colnam; /* name of collate table */ unsigned int xabkeydef$$_fill_14; /* spare */ unsigned int xabkeydef$$_fill_15; /* spare */ unsigned int xabkeydef$$_fill_16; /* spare */ /*-- */ /*++ */ } XABKEYDEF; #if !defined(__VAXC) #define xab$b_flg xab$r_flg_overlay.xab$b_flg #define xab$r_flg_bits0 xab$r_flg_overlay.xab$r_flg_bits0 #define xab$v_dup xab$r_flg_bits0.xab$v_dup #define xab$v_chg xab$r_flg_bits0.xab$v_chg #define xab$v_nul xab$r_flg_bits0.xab$v_nul #define xab$v_idx_ncmpr xab$r_flg_bits0.xab$v_idx_ncmpr #define xab$v_key_ncmpr xab$r_flg_bits0.xab$v_key_ncmpr #define xab$r_flg_bits1 xab$r_flg_overlay.xab$r_flg_bits1 #define xab$v_dat_ncmpr xab$r_flg_bits1.xab$v_dat_ncmpr #define xab$w_pos xab$r_pos_overlay.xab$w_pos #define xab$r_pos_fields xab$r_pos_overlay.xab$r_pos_fields #define xab$w_pos0 xab$r_pos_fields.xab$w_pos0 #define xab$w_pos1 xab$r_pos_fields.xab$w_pos1 #define xab$w_pos2 xab$r_pos_fields.xab$w_pos2 #define xab$w_pos3 xab$r_pos_fields.xab$w_pos3 #define xab$w_pos4 xab$r_pos_fields.xab$w_pos4 #define xab$w_pos5 xab$r_pos_fields.xab$w_pos5 #define xab$w_pos6 xab$r_pos_fields.xab$w_pos6 #define xab$w_pos7 xab$r_pos_fields.xab$w_pos7 #define xab$b_siz xab$r_siz_overlay.xab$b_siz #define xab$r_siz_fields xab$r_siz_overlay.xab$r_siz_fields #define xab$b_siz0 xab$r_siz_fields.xab$b_siz0 #define xab$b_siz1 xab$r_siz_fields.xab$b_siz1 #define xab$b_siz2 xab$r_siz_fields.xab$b_siz2 #define xab$b_siz3 xab$r_siz_fields.xab$b_siz3 #define xab$b_siz4 xab$r_siz_fields.xab$b_siz4 #define xab$b_siz5 xab$r_siz_fields.xab$b_siz5 #define xab$b_siz6 xab$r_siz_fields.xab$b_siz6 #define xab$b_siz7 xab$r_siz_fields.xab$b_siz7 #define xab$b_typ xab$r_typ_overlay.xab$b_typ #define xab$r_typ_fields xab$r_typ_overlay.xab$r_typ_fields #define xab$b_typ0 xab$r_typ_fields.xab$b_typ0 #define xab$b_typ1 xab$r_typ_fields.xab$b_typ1 #define xab$b_typ2 xab$r_typ_fields.xab$b_typ2 #define xab$b_typ3 xab$r_typ_fields.xab$b_typ3 #define xab$b_typ4 xab$r_typ_fields.xab$b_typ4 #define xab$b_typ5 xab$r_typ_fields.xab$b_typ5 #define xab$b_typ6 xab$r_typ_fields.xab$b_typ6 #define xab$b_typ7 xab$r_typ_fields.xab$b_typ7 #endif /* #if !defined(__VAXC) */ #else /* __OLD_STARLET */ #if !defined(__NOBASEALIGN_SUPPORT) && !defined(__cplusplus) /* If using pre DECC V4.0 or C++ */ #pragma __nomember_alignment __longword #else #pragma __nomember_alignment #endif struct xabkeydef { #pragma __nomember_alignment unsigned char xab$b_cod; /* xab id code */ unsigned char xab$b_bln; /* block length */ short int xabkeydef$$_fill_1; /* (spare) */ void *xab$l_nxt; /* xab chain link */ /* */ /* the field layout of the key xab is such that it matchs as */ /* closely as possible the layout of a key decriptor in the */ /* index file prologue. this is so the contents may be moved */ /* between the two structures as efficiently as possible. */ /* */ unsigned char xab$b_ian; /* index level area number */ unsigned char xab$b_lan; /* lowest index level area number */ unsigned char xab$b_dan; /* data level area number */ unsigned char xab$b_lvl; /* level of root bucket */ unsigned char xab$b_ibs; /* size of index buckets in virtual blocks */ unsigned char xab$b_dbs; /* size of data buckets in virtual blocks */ unsigned int xab$l_rvb; /* root bucket start vbn */ __union { unsigned char xab$b_flg; /* key option flags */ __struct { unsigned xab$v_dup : 1; /* duplicate key values allowed */ unsigned xab$v_chg : 1; /* alt key only --key field may change on update */ unsigned xab$v_nul : 1; /* alt key only --null key value enable */ unsigned xab$v_idx_ncmpr : 1; /* indicate index records for given key are not compressed */ unsigned xabkeydef$$_fill_5 : 2; /* spare */ unsigned xab$v_key_ncmpr : 1; /* indicates key is not compressed in data record */ unsigned xab$v_fill_14_ : 1; } xab$r_flg_bits0; __struct { unsigned xabkeydef$$_fill_6 : 1; /* space over dup */ unsigned xabkeydef$$_fill_7 : 2; /* spare */ unsigned xabkeydef$$_fill_8 : 1; /* space over idx_ncmpr */ unsigned xabkeydef$$_fill_9 : 2; /* spare */ unsigned xabkeydef$$_fill_10 : 1; /* space over key_ncmpr */ unsigned xab$v_dat_ncmpr : 1; /* data record is not compressed */ } xab$r_flg_bits1; } xab$r_flg_overlay; unsigned char xab$b_dtp; /* key field data type */ unsigned char xab$b_nsg; /* number of key segments */ unsigned char xab$b_nul; /* nul key character */ unsigned char xab$b_tks; /* total key field size (bytes) */ unsigned char xab$b_ref; /* key of reference (0=prim key, */ /* 1-254 = alternate keys) */ unsigned short int xab$w_mrl; /* minimun record length to contain key field */ unsigned short int xab$w_ifl; /* index bucket fill size (bytes) */ unsigned short int xab$w_dfl; /* data bucket fil size (bytes) */ __union { unsigned short int xab$w_pos [8]; /* key field record offset positions */ __struct { unsigned short int xab$w_pos0; /* segment 0 */ unsigned short int xab$w_pos1; /* segment 1 */ unsigned short int xab$w_pos2; /* segment 2 */ unsigned short int xab$w_pos3; /* segment 3 */ unsigned short int xab$w_pos4; /* segment 4 */ unsigned short int xab$w_pos5; /* segment 5 */ unsigned short int xab$w_pos6; /* segment 6 */ unsigned short int xab$w_pos7; /* segment 7 */ } xab$r_pos_fields; } xab$r_pos_overlay; __union { unsigned char xab$b_siz [8]; /* key field segment sizes */ __struct { unsigned char xab$b_siz0; /* segment 0 */ unsigned char xab$b_siz1; /* segment 1 */ unsigned char xab$b_siz2; /* segment 2 */ unsigned char xab$b_siz3; /* segment 3 */ unsigned char xab$b_siz4; /* segment 4 */ unsigned char xab$b_siz5; /* segment 5 */ unsigned char xab$b_siz6; /* segment 6 */ unsigned char xab$b_siz7; /* segment 7 */ } xab$r_siz_fields; } xab$r_siz_overlay; short int xabkeydef$$_fill_11; /* spare */ /* */ /* the positions of the above fields are dictated by the key descriptor */ /* record layout in the index file prologue. */ /* */ char *xab$l_knm; /* pointer to 32 character key name buffer */ unsigned int xab$l_dvb; /* first data bucket start vbn */ /* Additions for prologue 3 files */ /* */ __union { unsigned char xab$b_typ [8]; /* key field segment types */ __struct { unsigned char xab$b_typ0; /* segment 0 */ unsigned char xab$b_typ1; /* segment 1 */ unsigned char xab$b_typ2; /* segment 2 */ unsigned char xab$b_typ3; /* segment 3 */ unsigned char xab$b_typ4; /* segment 4 */ unsigned char xab$b_typ5; /* segment 5 */ unsigned char xab$b_typ6; /* segment 6 */ unsigned char xab$b_typ7; /* segment 7 */ } xab$r_typ_fields; } xab$r_typ_overlay; unsigned char xab$b_prolog; /* indicate prologue version desired (primary key only) */ char xabkeydef$$_fill_12; /* spare */ short int xabkeydef$$_fill_13; /* spare */ void *xab$l_coltbl; /* address of collate table */ unsigned int xab$l_colsiz; /* size of collate table */ char *xab$l_colnam; /* name of collate table */ unsigned int xabkeydef$$_fill_14; /* spare */ unsigned int xabkeydef$$_fill_15; /* spare */ unsigned int xabkeydef$$_fill_16; /* spare */ /*-- */ /*++ */ } ; #if !defined(__VAXC) #define xab$b_flg xab$r_flg_overlay.xab$b_flg #define xab$v_dup xab$r_flg_overlay.xab$r_flg_bits0.xab$v_dup #define xab$v_chg xab$r_flg_overlay.xab$r_flg_bits0.xab$v_chg #define xab$v_nul xab$r_flg_overlay.xab$r_flg_bits0.xab$v_nul #define xab$v_idx_ncmpr xab$r_flg_overlay.xab$r_flg_bits0.xab$v_idx_ncmpr #define xab$v_key_ncmpr xab$r_flg_overlay.xab$r_flg_bits0.xab$v_key_ncmpr #define xab$v_dat_ncmpr xab$r_flg_overlay.xab$r_flg_bits1.xab$v_dat_ncmpr #define xab$w_pos xab$r_pos_overlay.xab$w_pos #define xab$w_pos0 xab$r_pos_overlay.xab$r_pos_fields.xab$w_pos0 #define xab$w_pos1 xab$r_pos_overlay.xab$r_pos_fields.xab$w_pos1 #define xab$w_pos2 xab$r_pos_overlay.xab$r_pos_fields.xab$w_pos2 #define xab$w_pos3 xab$r_pos_overlay.xab$r_pos_fields.xab$w_pos3 #define xab$w_pos4 xab$r_pos_overlay.xab$r_pos_fields.xab$w_pos4 #define xab$w_pos5 xab$r_pos_overlay.xab$r_pos_fields.xab$w_pos5 #define xab$w_pos6 xab$r_pos_overlay.xab$r_pos_fields.xab$w_pos6 #define xab$w_pos7 xab$r_pos_overlay.xab$r_pos_fields.xab$w_pos7 #define xab$b_siz xab$r_siz_overlay.xab$b_siz #define xab$b_siz0 xab$r_siz_overlay.xab$r_siz_fields.xab$b_siz0 #define xab$b_siz1 xab$r_siz_overlay.xab$r_siz_fields.xab$b_siz1 #define xab$b_siz2 xab$r_siz_overlay.xab$r_siz_fields.xab$b_siz2 #define xab$b_siz3 xab$r_siz_overlay.xab$r_siz_fields.xab$b_siz3 #define xab$b_siz4 xab$r_siz_overlay.xab$r_siz_fields.xab$b_siz4 #define xab$b_siz5 xab$r_siz_overlay.xab$r_siz_fields.xab$b_siz5 #define xab$b_siz6 xab$r_siz_overlay.xab$r_siz_fields.xab$b_siz6 #define xab$b_siz7 xab$r_siz_overlay.xab$r_siz_fields.xab$b_siz7 #define xab$b_typ xab$r_typ_overlay.xab$b_typ #define xab$b_typ0 xab$r_typ_overlay.xab$r_typ_fields.xab$b_typ0 #define xab$b_typ1 xab$r_typ_overlay.xab$r_typ_fields.xab$b_typ1 #define xab$b_typ2 xab$r_typ_overlay.xab$r_typ_fields.xab$b_typ2 #define xab$b_typ3 xab$r_typ_overlay.xab$r_typ_fields.xab$b_typ3 #define xab$b_typ4 xab$r_typ_overlay.xab$r_typ_fields.xab$b_typ4 #define xab$b_typ5 xab$r_typ_overlay.xab$r_typ_fields.xab$b_typ5 #define xab$b_typ6 xab$r_typ_overlay.xab$r_typ_fields.xab$b_typ6 #define xab$b_typ7 xab$r_typ_overlay.xab$r_typ_fields.xab$b_typ7 #endif /* #if !defined(__VAXC) */ #endif /* #ifdef __NEW_STARLET */ /* basealign on aggregate XABKEYDEF operates after aggregate end */ #define XAB$K_KEYLEN 100 /* xabkey length for V5 */ #define XAB$C_KEYLEN 100 /* xabkey length for V5 */ /* These are traditional macros that should be hand-maintained for compatibility */ /* Do not have to add new ones, but do have to maintain those that are here already. */ #define XAB$V_DUP 0 /* duplicate key value allowed */ #define XAB$V_CHG 1 /* may change on update (alternate keys only) */ #define XAB$V_NUL 2 /* null key value enable (alternate keys only) */ #define XAB$V_IDX_NCMPR 3 /* indicates index records are not compressed */ #define XAB$V_KEY_NCMPR 6 /* indicates primary key is not compressed */ #define XAB$V_DAT_NCMPR 7 /* indicated data record is not compressed */ /* Note: if you wish to access these field as defined in the struct, * #undef these macros in your code */ #ifndef __cplusplus #undef xab$w_pos #define xab$w_pos xab$w_pos0 #undef xab$b_siz #define xab$b_siz xab$b_siz0 #undef xab$b_typ #define xab$b_typ xab$b_typ0 #endif #ifdef __NEW_STARLET #define XABKEY _xabkeydef #else #define XABKEY xabkeydef #endif #define cc$rms_xabkey (*decc$ga_rms_xabkey) #if defined(__DECC) || defined(__DECCXX) # pragma extern_model __save # pragma extern_model strict_refdef extern struct XABKEY cc$rms_xabkey; /* Declare initialized prototype data structures */ # pragma extern_model __restore #else globalref struct XABKEY cc$rms_xabkey; /* Declare initialized prototype data structures */ #endif #pragma __member_alignment __restore #ifdef __INITIAL_POINTER_SIZE /* Defined whenever ptr size pragmas supported */ #pragma __required_pointer_size __restore /* Restore the previously-defined required ptr size */ #endif #ifdef __cplusplus } #endif #pragma __standard #endif /* __XABKEYDEF_LOADED */