/********************************************************************************************************************************/ /* Created: 30-Mar-2010 17:29:35 by OpenVMS SDL EV3-3 */ /* Source: 30-MAR-2010 17:29:20 $1$DGA7274:[STARLET_H.SRC]LIBDTDEF.SDI;1 */ /********************************************************************************************************************************/ /*** MODULE $LIBDTDEF ***/ #ifndef __LIBDTDEF_LOADED #define __LIBDTDEF_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 /* */ /* Interface definitions for LIB$DT (date/time) package */ /* */ /* */ /* Request codes for LIB$INIT_DATE_TIME_CONTEXT */ /* */ #define LIB$K_MONTH_NAME 0 /*Pre-init the month names */ #define LIB$K_MONTH_NAME_ABB 3 /*Pre-init the month names */ #define LIB$K_WEEKDAY_NAME 6 /*Pre-init the week names */ #define LIB$K_WEEKDAY_NAME_ABB 9 /*Pre-init the week names */ #define LIB$K_MERIDIEM_INDICATOR 12 /*Pre-init the AM/PM names */ #define LIB$K_OUTPUT_FORMAT 1 /*Pre-init the format */ #define LIB$K_INPUT_FORMAT 2 /*Pre-init the format */ #define LIB$K_RELATIVE_DAY_NAME 15 /*Pre-init "TODAY", etc. */ #define LIB$K_FORMAT_MNEMONICS 18 /*Pre-init MM, DD, YYYY, etc. */ #define LIB$K_LANGUAGE 4 /*Pre-init user's language */ /* */ /* Operation codes (flags) for date time conversion routines. */ /* NOTE: any new operation codes MUST be added just BEFORE MAX_OPERATION */ /* */ #define LIB$K_MONTH_OF_YEAR 1 /* requests output in units of month of year */ #define LIB$K_DAY_OF_YEAR 2 /* requests output in days of year 1-366 */ #define LIB$K_HOUR_OF_YEAR 3 /* requests output in hours of year 1-8784 */ #define LIB$K_MINUTE_OF_YEAR 4 /* requests output in minutes of year 1-527040 */ #define LIB$K_SECOND_OF_YEAR 5 /* requests output in seconds of year 1-31622400 */ #define LIB$K_DAY_OF_MONTH 6 /* request output in days of month 1-31 */ #define LIB$K_HOUR_OF_MONTH 7 /* request output in hours of month 1-744 */ #define LIB$K_MINUTE_OF_MONTH 8 /* request output in minutes of month 1-44640 */ #define LIB$K_SECOND_OF_MONTH 9 /* requests output in seconds of month 1-2678400 */ #define LIB$K_DAY_OF_WEEK 10 /* requests output in days of week 1-7 with monday = 1 */ #define LIB$K_HOUR_OF_WEEK 11 /* requests output in hours of week 1-168 */ #define LIB$K_MINUTE_OF_WEEK 12 /* requests in minutes of week 1-10080 */ #define LIB$K_SECOND_OF_WEEK 13 /* requests output in seconds of week 1-604800 */ #define LIB$K_HOUR_OF_DAY 14 /* requests output in hours of day 1-24 */ #define LIB$K_MINUTE_OF_DAY 15 /* requests output in minutes of day 1-1440 */ #define LIB$K_SECOND_OF_DAY 16 /* requests output in seconds of day 1-3600 */ #define LIB$K_MINUTE_OF_HOUR 17 /* requests output in minutes of hour 1-60 */ #define LIB$K_SECOND_OF_HOUR 18 /* requests output in minutes of hour 1-3600 */ #define LIB$K_SECOND_OF_MINUTE 19 /* requests output in seconds of minutes 1-60 */ #define LIB$K_JULIAN_DATE 20 /* requests output as a julian day number */ #define LIB$K_DELTA_WEEKS 21 /* input/output in terms of delta weeks */ #define LIB$K_DELTA_DAYS 22 /* input/output in terms of delta days */ #define LIB$K_DELTA_HOURS 23 /* input/output in terns of delta hours */ #define LIB$K_DELTA_MINUTES 24 /* input/output in terms of delta minutes */ #define LIB$K_DELTA_SECONDS 25 /* input/output in terms of delta seconds */ #define LIB$K_DELTA_WEEKS_F 26 /* input/output in terms of fractional delta weeks */ #define LIB$K_DELTA_DAYS_F 27 /* input/output in terms of fractional delta days */ #define LIB$K_DELTA_HOURS_F 28 /* input/output in terms of fractional delta hours */ #define LIB$K_DELTA_MINUTES_F 29 /* input/output in terms of fractional delta minutess */ #define LIB$K_DELTA_SECONDS_F 30 /* input/output in terms of fractional delta seconds */ #define LIB$K_MAX_OPERATION 31 /* 1+ max # of conversion flags */ /* */ /* Masks for outputting date or time fields only */ /* */ #define LIB$M_TIME_FIELDS 0x1 #define LIB$M_DATE_FIELDS 0x2 #ifdef __NEW_STARLET typedef struct _dt_print_fields { unsigned lib$v_time_fields : 1; /* Force printing of time fields */ unsigned lib$v_date_fields : 1; /* Force printing of date fields */ unsigned lib$v_fill_0_ : 6; } DT_PRINT_FIELDS; #else /* __OLD_STARLET */ struct dt_print_fields { unsigned lib$v_time_fields : 1; /* Force printing of time fields */ unsigned lib$v_date_fields : 1; /* Force printing of date fields */ unsigned lib$v_fill_0_ : 6; } ; #endif /* #ifdef __NEW_STARLET */ /* */ /* Masks for input defaulting flag longword */ /* */ #define LIB$M_YEAR 0x1 #define LIB$M_MONTH 0x2 #define LIB$M_DAY 0x4 #define LIB$M_HOUR 0x8 #define LIB$M_MINUTE 0x10 #define LIB$M_SECOND 0x20 #define LIB$M_HUNDREDTHS 0x40 #ifdef __NEW_STARLET typedef struct _dt_default_fields { unsigned lib$v_year : 1; /* Allow the year to be defaulted */ unsigned lib$v_month : 1; /* Allow the month to be defaulted */ unsigned lib$v_day : 1; /* Allow the day to be defaulted */ unsigned lib$v_hour : 1; /* Allow the hour to be defaulted */ unsigned lib$v_minute : 1; /* Allow the minute to be defaulted */ unsigned lib$v_second : 1; /* Allow the second to be defaulted */ unsigned lib$v_hundredths : 1; /* Allow the fract to be defaulted */ unsigned lib$v_fill_1_ : 1; } DT_DEFAULT_FIELDS; #else /* __OLD_STARLET */ struct dt_default_fields { unsigned lib$v_year : 1; /* Allow the year to be defaulted */ unsigned lib$v_month : 1; /* Allow the month to be defaulted */ unsigned lib$v_day : 1; /* Allow the day to be defaulted */ unsigned lib$v_hour : 1; /* Allow the hour to be defaulted */ unsigned lib$v_minute : 1; /* Allow the minute to be defaulted */ unsigned lib$v_second : 1; /* Allow the second to be defaulted */ unsigned lib$v_hundredths : 1; /* Allow the fract to be defaulted */ unsigned lib$v_fill_1_ : 1; } ; #endif /* #ifdef __NEW_STARLET */ #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 /* __LIBDTDEF_LOADED */