File: timer.h

package info (click to toggle)
craft 3.5-10
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 18,000 kB
  • ctags: 1,602
  • sloc: cpp: 3,794; makefile: 2,319; ansic: 857; sh: 385
file content (31 lines) | stat: -rw-r--r-- 571 bytes parent folder | download | duplicates (4)
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
#include "stdio.h"
#include "sys/types.h"
#include "sys/times.h"
#include "sys/time.h"

/*----------------------------------------------------------------------*/
/* CLASS timer (deklarations)                                           */
/*----------------------------------------------------------------------*/

#ifndef timer_h
#define timer_h

class timer
  {private :

     long   stamp;
     double dt;

   public :

     void   start ();
     void   stop  ();
     double read  ();
     double exec  ();
     void   delay (int dt);

  };

long sys_time ();

#endif