INET Framework for OMNeT++/OMNEST
inet::ElapsedTimeRecorder Class Reference

#include <ResultRecorders.h>

Inheritance diagram for inet::ElapsedTimeRecorder:

Public Member Functions

 ElapsedTimeRecorder ()
 
virtual void finish (cResultFilter *prev) override
 

Protected Member Functions

virtual void receiveSignal (cResultFilter *prev, simtime_t_cref t, bool b, cObject *details) override
 
virtual void receiveSignal (cResultFilter *prev, simtime_t_cref t, long l, cObject *details) override
 
virtual void receiveSignal (cResultFilter *prev, simtime_t_cref t, unsigned long l, cObject *details) override
 
virtual void receiveSignal (cResultFilter *prev, simtime_t_cref t, double d, cObject *details) override
 
virtual void receiveSignal (cResultFilter *prev, simtime_t_cref t, const SimTime &v, cObject *details) override
 
virtual void receiveSignal (cResultFilter *prev, simtime_t_cref t, const char *s, cObject *details) override
 
virtual void receiveSignal (cResultFilter *prev, simtime_t_cref t, cObject *obj, cObject *details) override
 

Protected Attributes

clock_t startTime
 

Constructor & Destructor Documentation

inet::ElapsedTimeRecorder::ElapsedTimeRecorder ( )
76 {
77  startTime = clock();
78 }
clock_t startTime
Definition: ResultRecorders.h:51

Member Function Documentation

void inet::ElapsedTimeRecorder::finish ( cResultFilter *  prev)
overridevirtual
81 {
82  clock_t t = clock();
83  double elapsedTime = (t - startTime) / (double)CLOCKS_PER_SEC;
84  opp_string_map attributes = getStatisticAttributes();
85  getEnvir()->recordScalar(getComponent(), getResultName().c_str(), elapsedTime, &attributes);
86 }
clock_t startTime
Definition: ResultRecorders.h:51
virtual void inet::ElapsedTimeRecorder::receiveSignal ( cResultFilter *  prev,
simtime_t_cref  t,
bool  b,
cObject *  details 
)
inlineoverrideprotectedvirtual
53 {}
virtual void inet::ElapsedTimeRecorder::receiveSignal ( cResultFilter *  prev,
simtime_t_cref  t,
long  l,
cObject *  details 
)
inlineoverrideprotectedvirtual
54 {}
virtual void inet::ElapsedTimeRecorder::receiveSignal ( cResultFilter *  prev,
simtime_t_cref  t,
unsigned long  l,
cObject *  details 
)
inlineoverrideprotectedvirtual
55 {}
virtual void inet::ElapsedTimeRecorder::receiveSignal ( cResultFilter *  prev,
simtime_t_cref  t,
double  d,
cObject *  details 
)
inlineoverrideprotectedvirtual
56 {}
virtual void inet::ElapsedTimeRecorder::receiveSignal ( cResultFilter *  prev,
simtime_t_cref  t,
const SimTime &  v,
cObject *  details 
)
inlineoverrideprotectedvirtual
57 {}
virtual void inet::ElapsedTimeRecorder::receiveSignal ( cResultFilter *  prev,
simtime_t_cref  t,
const char *  s,
cObject *  details 
)
inlineoverrideprotectedvirtual
58 {}
virtual void inet::ElapsedTimeRecorder::receiveSignal ( cResultFilter *  prev,
simtime_t_cref  t,
cObject *  obj,
cObject *  details 
)
inlineoverrideprotectedvirtual
59 {}

Member Data Documentation

clock_t inet::ElapsedTimeRecorder::startTime
protected

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