home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Misc / DC-POS24.LZX / pOS / IncPOS.lzx / pLib / Time.c < prev   
Encoding:
C/C++ Source or Header  |  1997-03-18  |  1.2 KB  |  53 lines

  1. #ifndef __INC_POS_PLIB_TIME_C
  2. #define __INC_POS_PLIB_TIME_C
  3. /*******************************************************************
  4.  $CRT 18 Mar 1996 : hb
  5.  
  6.  $AUT Holger Burkarth
  7.  $DAT >>Time.c<<   24 Nov 1996    18:29:35 - (C) ProDAD
  8. *******************************************************************/
  9.  
  10. // mcpp:cppc -c p:pLib/Time.c
  11.  
  12.  
  13. #ifdef __cplusplus
  14. extern "C" {
  15. #endif
  16.  
  17.  #include <time.h>
  18.  
  19. #ifdef __cplusplus
  20. }
  21. #endif
  22.  
  23. #include "p:pDOS/Files.h"
  24.  
  25. #include "p:proto/pDOS2.h"
  26. #include "p:pDOS/DosBase.h"
  27.  
  28. /*----------------------------------
  29. -----------------------------------*/
  30. clock_t clock(void);
  31. double difftime(time_t _time1, time_t _time2);
  32.  
  33. time_t mktime(struct tm *_timeptr);
  34.  
  35. time_t time(time_t *_timer)
  36. {
  37.   struct pOS_DateStamp DS;
  38.   struct pOS_GetDateStamp(&DS);
  39.   return((DS.ds_Days<<17) + DS.ds_Minute*60 + DS.ds_Tick/pOS_TICKS_PER_SECOND);
  40. }
  41.  
  42. char *asctime(const struct tm *_timeptr);
  43. char *ctime(const time_t *_timer);
  44. struct tm *gmtime(const time_t *_timer) ; // durchlassen
  45. struct tm *localtime(const time_t *_timer) ; // durchlassen
  46.  
  47. size_t strftime(char *_s, size_t _maxsize,const char *_format,
  48.                 const struct tm *_timeptr);  // durchlassen
  49.  
  50.  
  51.  
  52. #endif
  53.