STLdoc
STLdocumentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
xtimec.h
Go to the documentation of this file.
1 /* xtimec.h -- header for high-resolution time functions */
2 #pragma once
3 #ifndef _THR_XTIMEC_H
4 #define _THR_XTIMEC_H
5 #ifndef RC_INVOKED
6 #include <thr/xthrcommon.h>
7 #include <time.h>
8 
9  #pragma pack(push,_CRT_PACKING)
10  #pragma warning(push,3)
11  #pragma push_macro("new")
12  #undef new
13 
14 #ifdef __cplusplus
15 extern "C" { // C linkage
16 #endif /* __cplusplus */
17 
18 enum { /* define TIME_UTC */
20  };
21 
22 typedef struct xtime
23  { /* store time with nanosecond resolution */
25  long nsec;
26  } xtime;
27 
28 _CRTIMP2_PURE int __cdecl xtime_get(xtime*, int);
29 
30 _CRTIMP2_PURE long __cdecl _Xtime_diff_to_millis(const xtime *);
31 _CRTIMP2_PURE long __cdecl _Xtime_diff_to_millis2(const xtime*, const xtime *);
33 #define _XTIME_NSECS_PER_TICK 100
34 #define _XTIME_TICKS_PER_TIME_T (_LONGLONG)10000000
35 
36 #ifdef __cplusplus
37 } // extern "C"
38 #endif
39  #pragma pop_macro("new")
40  #pragma warning(pop)
41  #pragma pack(pop)
42 #endif /* RC_INVOKED */
43 #endif /* _THR_XTIMEC_H */
44 
45 /*
46  * This file is derived from software bearing the following
47  * restrictions:
48  *
49  * (c) Copyright William E. Kempf 2001
50  *
51  * Permission to use, copy, modify, distribute and sell this
52  * software and its documentation for any purpose is hereby
53  * granted without fee, provided that the above copyright
54  * notice appear in all copies and that both that copyright
55  * notice and this permission notice appear in supporting
56  * documentation. William E. Kempf makes no representations
57  * about the suitability of this software for any purpose.
58  * It is provided "as is" without express or implied warranty.
59  */
60 
61 /*
62  * Copyright (c) 1992-2012 by P.J. Plauger. ALL RIGHTS RESERVED.
63  * Consult your license regarding permissions and restrictions.
64 V6.00:0009 */
__time64_t time_t
Definition: crtdefs.h:580
_CRTIMP2_PURE _LONGLONG __cdecl _Xtime_get_ticks()
struct xtime xtime
Definition: xtimec.h:19
_CRTIMP2_PURE long __cdecl _Xtime_diff_to_millis2(const xtime *, const xtime *)
Definition: xtimec.h:22
_CRTIMP2_PURE int __cdecl xtime_get(xtime *, int)
#define _LONGLONG
Definition: yvals.h:574
_CRTIMP2_PURE long __cdecl _Xtime_diff_to_millis(const xtime *)
time_t sec
Definition: xtimec.h:24
long nsec
Definition: xtimec.h:25
#define _CRTIMP2_PURE
Definition: yvals.h:483