root/library/tests/unittest-cpp/Posix/TimeHelpers.h
@
706
Revision 706, 291 bytes (checked in by smidl, 15 years ago) | |
---|---|
|
Rev | Line | |
---|---|---|
[418] | 1 | #ifndef UNITTEST_TIMEHELPERS_H |
2 | #define UNITTEST_TIMEHELPERS_H | |
3 | ||
4 | #include <sys/time.h> | |
5 | ||
6 | namespace UnitTest { | |
7 | ||
[477] | 8 | class Timer { |
[418] | 9 | public: |
[477] | 10 | Timer(); |
11 | void Start(); | |
12 | double GetTimeInMs() const; | |
[418] | 13 | |
14 | private: | |
[477] | 15 | struct timeval m_startTime; |
[418] | 16 | }; |
17 | ||
18 | ||
[477] | 19 | namespace TimeHelpers { |
20 | void SleepMs ( int ms ); | |
[418] | 21 | } |
22 | ||
23 | ||
24 | } | |
25 | ||
26 | #endif |
Note: See TracBrowser
for help on using the browser.