home *** CD-ROM | disk | FTP | other *** search
/ Mac Power 1999 February / MACPOWER-1999-02.ISO.7z / MACPOWER-1999-02.ISO / 9902⁄AMUG / UTILITY / mac06-0.95.sit / mac06-0.95 / usr / include / time.h < prev    next >
Text File  |  1998-11-08  |  1KB  |  67 lines

  1. /* mac06ゥ1997 by HNS/DSITRI hns@computer.org
  2. ** time.h
  3. */
  4.  
  5. #pragma once
  6.  
  7. #include "size_t.h"
  8. #include "clock_t.h"
  9. #include "time_t.h"
  10.  
  11. #ifndef NULL
  12. #define NULL            (0)
  13. #endif
  14.  
  15. #ifdef __SC__    /* Symantec C++ for PowerPC 8.0 */
  16. #pragma options align=mac68k
  17. #endif
  18.  
  19. #ifndef _POSIX_SOURCE
  20. struct timeval
  21.     {
  22.     unsigned long tv_sec;
  23.     unsigned long tv_usec;
  24.     };
  25.  
  26. struct timezone
  27.     {
  28.     short tz_minuteswest;
  29.     unsigned short tz_dstime;
  30.     };
  31. #endif
  32.  
  33. struct tm
  34.     {
  35.     unsigned short tm_sec;
  36.     unsigned short tm_min;
  37.     unsigned short tm_hour;
  38.     unsigned short tm_mday;    /* month day (1...31) */
  39.     unsigned short tm_mon;    /* month (0=Jan ... 11=Dec) */
  40.     unsigned short tm_wday;    /* day of week (0=Sunday) */
  41.     short tm_year;                /* full year number */
  42.     unsigned short tm_yday;    /* days since Jan 1. */
  43.     unsigned short tm_isdst;    /* daylight savings flag */
  44.     };
  45.  
  46. #ifdef __SC__
  47. #pragma options align=reset
  48. #endif
  49.  
  50. extern char *tzname[2];
  51.  
  52. char *asctime(const struct tm *tp);
  53. clock_t clock(void);
  54. #define ctime(tp) asctime(gmtime(tp))
  55. /* double difftime(time_t t1, time_t t0); */
  56. struct tm *gmtime(const time_t *tp);
  57. struct tm *localtime(const time_t *tp);
  58. time_t mktime(struct tm *tp);
  59. size_t strftime(char *s, size_t size, const char *fmt, const struct tm *tp);
  60. time_t time(time_t *tp);
  61. void tzset(void);
  62. #ifndef _POSIX_SOURCE
  63. int gettimeofday(struct timeval *, struct timezone *);
  64. #endif
  65.  
  66.  
  67. /* EOF */