| kspaceFirstOrder3D-OMP 1.0 The C++ implementation of the k-wave toolbox for the time-domain simulation of acoustic wave fields in 3D

- Main Page
- Classes
- Files

- File List
- File Members

Utils/TimeMeasure.h
Go to the documentation of this file.

    00001
    00032 #ifndef TIMEMEASURE_H
    00033 #define  TIMEMEASURE_H
    00034
    00035 #include <omp.h>
    00036
    00041 class TTimeMesssure{
    00042 public :
    00044     double StartTime;
    00046     double StopTime;
    00047
    00049     TTimeMesssure() : StartTime(0.0), StopTime(0.0) {};
    00050
    00055     TTimeMesssure(const TTimeMesssure & src) :
    00056         StartTime(src.StartTime),
    00057         StopTime (src.StopTime) { };
    00058
    00064     TTimeMesssure& operator = (const TTimeMesssure & src){
    00065         if (this != &src){
    00066             StartTime = src.StartTime;
    00067             StopTime  = src.StopTime;
    00068         }
    00069         return *this;
    00070     };
    00071
    00072
    00074     virtual ~TTimeMesssure() {};
    00075
    00077     void Start() {StartTime = omp_get_wtime(); };
    00079     void Stop()  {StopTime = omp_get_wtime();};
    00080
    00085     double GetElapsedTime() const {return StopTime - StartTime;};
    00086 };// end of TTimeMesssure
    00087 //------------------------------------------------------------------------------
    00088
    00089 #endif   /* TIMEMEASURE_H */
    00090

All Classes Files Functions Variables Typedefs Enumerations