PandaRoot
PndCATimerInfo Class Reference

#include <PndCATimer.h>

Public Member Functions

 PndCATimerInfo ()
 
 PndCATimerInfo (const string &name)
 
void Clear ()
 
void operator= (TStopwatch &sw)
 
void operator+= (TStopwatch &sw)
 
void operator+= (const PndCATimerInfo &t)
 
PndCATimerInfo operator/ (const float f) const
 
void PrintReal ()
 
float Real ()
 
string & Name ()
 

Detailed Description

Definition at line 38 of file PndCATimer.h.

Constructor & Destructor Documentation

◆ PndCATimerInfo() [1/2]

PndCATimerInfo::PndCATimerInfo ( )
inline

Definition at line 40 of file PndCATimer.h.

Referenced by PndCATFIterTimerInfo::Add().

40 : fName(""), fReal(0), fCpu(0){};

◆ PndCATimerInfo() [2/2]

PndCATimerInfo::PndCATimerInfo ( const string &  name)
inline

Definition at line 41 of file PndCATimer.h.

41 : fName(name), fReal(0), fCpu(0){};

Member Function Documentation

◆ Clear()

void PndCATimerInfo::Clear ( void  )
inline

Definition at line 43 of file PndCATimer.h.

Referenced by PndCATFIterTimerInfo::Clear(), and PndCATFTimerInfo::Clear().

44  {
45  fReal = 0;
46  fCpu = 0;
47  }

◆ Name()

string& PndCATimerInfo::Name ( )
inline

Definition at line 76 of file PndCATimer.h.

Referenced by PndCATFIterTimerInfo::PrintReal().

76 { return fName; };

◆ operator+=() [1/2]

void PndCATimerInfo::operator+= ( TStopwatch &  sw)
inline

Definition at line 54 of file PndCATimer.h.

55  {
56  fReal += sw.RealTime();
57  fCpu += sw.CpuTime();
58  };

◆ operator+=() [2/2]

void PndCATimerInfo::operator+= ( const PndCATimerInfo t)
inline

Definition at line 59 of file PndCATimer.h.

60  {
61  fReal += t.fReal;
62  fCpu += t.fCpu;
63  }

◆ operator/()

PndCATimerInfo PndCATimerInfo::operator/ ( const float  f) const
inline

Definition at line 64 of file PndCATimer.h.

References f.

65  {
67  r.fName = fName;
68  r.fReal = fReal / f;
69  r.fCpu = fCpu / f;
70  return r;
71  }
float f
Definition: P4_F32vec4.h:32

◆ operator=()

void PndCATimerInfo::operator= ( TStopwatch &  sw)
inline

Definition at line 49 of file PndCATimer.h.

50  {
51  fReal = sw.RealTime();
52  fCpu = sw.CpuTime();
53  };

◆ PrintReal()

void PndCATimerInfo::PrintReal ( )
inline

Definition at line 74 of file PndCATimer.h.

74 { cout << fReal; };

◆ Real()

float PndCATimerInfo::Real ( )
inline

Definition at line 75 of file PndCATimer.h.

75 { return fReal; };

The documentation for this class was generated from the following file: