Files
sicspsi/tecs/myc_time.h
cvs 064ec37e9a - Rearranged directory structure for forking out ANSTO
- Refactored site specific stuff into a site module
- PSI specific stuff is now in the PSI directory.
- The old version has been tagged with pre-ansto
2003-06-20 10:18:47 +00:00

43 lines
888 B
C

#ifndef _MYC_TIME_H_
#define _MYC_TIME_H_
#define MYC_TIME_BASE 20010101
int mycNow(void);
/*
return seconds since a Monday specified by MYC_TIME_BASE
mycNow() % (24*3600) is always 0 at 00:00 even in daylight saving time
*/
int mycMsecSince(int since);
/*
mycMsecSince(0) return milliseconds since midnight
mycMsecSince(x) return milliseconds since x (x is time since midnight)
*/
int mycDate(int time);
/*
return year * 10000 + month * 100 + day_of_month of a time obtained by mycNow
year > 1900
1 <= month <= 12
1 <= day_of_month <= 31
*/
int mycTime(int date);
/*
does the inverse of MycDate. Chooses the last possible date not later than today
*/
/* the following subroutines are to be called from FORTRAN
integer function myc_now()
real function myc_date(time)
integer function myc_time(date)
integer time
real date
*/
#endif /* _MYC_TIME_H_ */