-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathTimer.h
More file actions
32 lines (29 loc) · 669 Bytes
/
Timer.h
File metadata and controls
32 lines (29 loc) · 669 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
/***************************************************************************************
*
* Copyright (c) 2014 Lejent, Inc. All Rights Reserved
*
**************************************************************************************/
/**
* @file: Timer.h
* @author: zhangxingbiao(xingbiao.zhang@lejent.com)
* @date: 09/28/2016 04:44:47 PM
* @version: 1.0
* @brief:
*
**/
#ifndef __TIMER_H__
#define __TIMER_H__
#include <sys/time.h>
class Timer {
public:
Timer(){
}
void start();
void stop();
long get_time_cost();
long get_current_time();
private:
struct timeval _begin;
struct timeval _end;
};
#endif