Blame view

src/utiltools.hpp 385 Bytes
92989af0   ming   更新解码器
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
  #ifndef _UTIL_TOOLS_HPP_
  #define _UTIL_TOOLS_HPP_
  
  #include<chrono>
  
  using namespace std;
  
  namespace UtilTools{
  
      static long get_cur_time_ms() {
          chrono::time_point<chrono::system_clock, chrono::milliseconds> tpMicro
              = chrono::time_point_cast<chrono::milliseconds>(chrono::system_clock::now());
          return tpMicro.time_since_epoch().count();
      }
  
  }
  
  #endif