winIDEA SDK
isys::CTestProfilerTime Class Reference

Description

This class stores expected profiler results for one time type (net, call, gross, ...).

 

#include <CTestProfilerStatistics.h>

Inheritance diagram for isys::CTestProfilerTime:
isys::CTestBase

Public Types

enum  EProfilerTimeSectionId {
  E_SECTION_MIN_TIME , E_SECTION_MIN_START_TIME ,
  E_SECTION_MIN_END_TIME , E_SECTION_MAX_TIME ,
  E_SECTION_MAX_START_TIME , E_SECTION_MAX_END_TIME ,
  E_SECTION_TOTAL_TIME , E_SECTION_AVERAGE_TIME
}
 Ids of test specification sections. More...
 

Public Member Functions

std::string getTime (EProfilerTimeSectionId profilerStatSectionId, int idx)
 Returns expected interval boundary for the given time type. More...
 
void setTime (EProfilerTimeSectionId profilerStatSectionId, const std::string &time, int idx)
 Sets time for the given section.
 
virtual bool isEmpty () const
 This method returns true, if the object contains no data.
 
virtual void serialize (const isys::IEmitterSPtr &emitter)
 Sends contents of this class to emitter.
 
virtual std::string toString ()
 Returns object data as YAML string.
 

Static Public Member Functions

static CTestProfilerTimeSPtr cast (const CTestBaseSPtr &testBase)
 Casts the given object to this class. More...
 
static double a2d (const std::string &strNum)
 Converts string to double. More...
 

Protected Member Functions

void setStaticTagsAsConst ()
 This method is called by all objects which are immediately contained in CTestSpecification, for example CTestCoverage, CTestHIL, ...
 

Member Enumeration Documentation

◆ EProfilerTimeSectionId

Ids of test specification sections.

Enumerator
E_SECTION_MIN_TIME 

min time ID

E_SECTION_MIN_START_TIME 

min start time ID

E_SECTION_MIN_END_TIME 

min end time ID

E_SECTION_MAX_TIME 

max time ID

E_SECTION_MAX_START_TIME 

max start time ID

E_SECTION_MAX_END_TIME 

max end time ID

E_SECTION_TOTAL_TIME 

total time ID

E_SECTION_AVERAGE_TIME 

average time ID

Member Function Documentation

◆ a2d()

static double isys::CTestProfilerTime::a2d ( const std::string &  strNum)
static

Converts string to double.

Parameters
strNumstring number, which may contain underscores for better readability, and may have time unit appended: ns, us, ms, s. If there is no unit appended, ns is assumed. Underscore is not allowed as the first character.

◆ cast()

static CTestProfilerTimeSPtr isys::CTestProfilerTime::cast ( const CTestBaseSPtr testBase)
static

Casts the given object to this class.

Returns NULL if input is NULL.

Exceptions
IllegalArgumentExceptionif input object is not instance of this class.

◆ getTime()

std::string isys::CTestProfilerTime::getTime ( EProfilerTimeSectionId  profilerStatSectionId,
int  idx 
)

Returns expected interval boundary for the given time type.

Parameters
profilerStatSectionIdID of profiler time section.
idxshould be 0 for lower boundary, 1 for upper boundary