home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 7 / 07.iso / c / c021 / 7.img / INCLUDE.ZIP / TIME.H < prev    next >
Encoding:
C/C++ Source or Header  |  1990-05-04  |  1.6 KB  |  82 lines

  1. /*    time.h
  2.  
  3.     Struct and function declarations for dealing with time.
  4.  
  5.         Copyright (c) Borland International 1987,1988,1990
  6.     All Rights Reserved.
  7. */
  8.  
  9. #ifndef __TIME_H
  10. #define __TIME_H
  11.  
  12. #if __STDC__
  13. #define _Cdecl
  14. #else
  15. #define _Cdecl    cdecl
  16. #endif
  17.  
  18. #ifndef __PAS__
  19. #define _CType _Cdecl
  20. #else
  21. #define _CType pascal
  22. #endif
  23.  
  24. #ifndef _SIZE_T
  25. #define _SIZE_T
  26. typedef unsigned size_t;
  27. #endif
  28.  
  29. #ifndef  _TIME_T
  30. #define  _TIME_T
  31. typedef long time_t;
  32. #endif
  33.  
  34. #ifndef  _CLOCK_T
  35. #define  _CLOCK_T
  36. typedef long clock_t;
  37.  
  38. #define CLOCKS_PER_SEC 18.2
  39. #define CLK_TCK        18.2
  40. #endif
  41.  
  42. struct tm
  43. {
  44.   int    tm_sec;
  45.   int    tm_min;
  46.   int    tm_hour;
  47.   int    tm_mday;
  48.   int    tm_mon;
  49.   int    tm_year;
  50.   int    tm_wday;
  51.   int    tm_yday;
  52.   int    tm_isdst;
  53. };
  54.  
  55. #ifdef __cplusplus
  56. extern "C" {
  57. #endif
  58. char *        _Cdecl asctime   (const struct tm *__tblock);
  59. char *        _Cdecl ctime     (const time_t *__time);
  60. double        _Cdecl difftime  (time_t __time2, time_t __time1);
  61. struct tm * _Cdecl gmtime    (const time_t *__timer);
  62. struct tm * _Cdecl localtime (const time_t *__timer);
  63. time_t      _Cdecl time      (time_t *__timer);
  64. time_t      _Cdecl mktime    (struct tm *__timeptr);
  65. clock_t     _Cdecl clock     (void);
  66. size_t        _Cdecl strftime  (char *__s, size_t __maxsize, const char *__fmt, const struct tm *__t);
  67.  
  68. #if !__STDC__
  69. extern int    _Cdecl    daylight;
  70. extern long    _Cdecl    timezone;
  71. extern char * const _Cdecl tzname[2];
  72.  
  73. int            _Cdecl    stime    (time_t *__tp);
  74. void        _Cdecl    tzset    (void);
  75. #endif
  76.  
  77. #ifdef __cplusplus
  78. }
  79. #endif
  80.  
  81. #endif
  82.