winIDEA SDK
Loading...
Searching...
No Matches
isys::CTestAnalyzerProfiler Class Reference

This class contains specification for profiler recording during test execution. More...

#include <CTestAnalyzerProfiler.h>

Inheritance diagram for isys::CTestAnalyzerProfiler:
isys::CTestBase

Public Types

enum  EAreaType { DATA_AREA , CODE_AREA }
 Profiler areas. More...

Public Member Functions

virtual void assign (const CTestObjectSPtr &base)
 Assigns members of base to this.
void assignCodeAreas (isys::CTestAnalyzerProfilerSPtr &src)
 This method copies code areas from src to this object.
void assignDataAreas (isys::CTestAnalyzerProfilerSPtr &src)
 This method copies code areas from src to this object.
bool containsSection (int section) const
 Returns true, if the specified section exists for this object.
virtual CTestObjectSPtr copy () const
 Creates a deep copy of this object.
CTestBaseSPtr createInstance (const CTestBaseSPtr &parent) const
 Creates a new empty instance of this class.
 CTestAnalyzerProfiler ()
 Initializes new instance.
 CTestAnalyzerProfiler (const CTestBaseSPtr &parent)
 Initializes new instance.
int findArea (const std::string &areaName, const std::string &areaValue)
 Returns index of the data area, or -1 if the area is not found.
int findArea (EAreaType areaType, const std::string &areaName)
 Returns index of the area or -1 if the area is not found.
isys::CTestProfilerStatisticsSPtr getArea (EAreaType areaType, int idx)
 Returns the requested area.
CTestBaseListSPtr getAreas (EAreaType areaType, bool isConst)
 Returns areas of the given type.
std::string getClassName () const
CTestBaseListSPtr getCodeAreas (bool isConst)
 Returns code areas specified for profiler.
virtual CTestTreeNodeSPtr getContainerTestNode ()
 virtual CTestSpecificationSPtr getContainerTestSpec();
CTestBaseListSPtr getDataAreas (bool isConst)
 Returns code areas specified for profiler.
int getEnumTagValue (int section)
 Returns value of enum type.
std::string getExportFileName ()
 Returns the export file name.
EProfilerExportFormat getExportFormat ()
 Returns the export format.
CTestBaseSPtr getParent () const
 Returns parent.
int getSectionId (const std::string &sectionName)
 Returns section ID for the given section name.
CTestBaseSPtr getTestBase (int section, bool isConst)
CTestBaseListSPtr getTestBaseList (int section, bool isConst)
CTestObject::ETestObjType getTestObjType () const
 Returns type of this object, which is CTestObject::ETestBase.
iconnect::ETristate isActive ()
 Returns E_TRUE if this section is active (export is performed, and analysis is run for coverage and profiler).
virtual bool isEmpty () const
 This method returns true, if the object contains no data.
iconnect::ETristate isExportActiveAreasOnly ()
 Returns true, when only areas with recoded activity will be exported.
iconnect::ETristate isMeasureAllFunctions ()
 Returns E_TRUE, if all functions should be measured, not only ones from code areas list.
bool isMerged () const
 Returns true, if the CTestSpecification section containing this object is merged.
iconnect::ETristate isProfileAUX ()
 Returns true, if AUX signals should be recorded during profiler session.
iconnect::ETristate isSaveHistory ()
 Returns true, if profiler history should also be saved to output file.
bool isSectionEmpty (int sectionId)
 Returns true, if the given section is empty.
virtual bool isSerializedAsList (bool isParsing)
 Returns true if object should be serialized as list, for example CTestFunction.
virtual void serialize (const isys::IEmitterSPtr &emitter)
 Sends contents of this class to emitter.
void setActive (iconnect::ETristate isActive)
 If isActive == true, recording is exported and analysis is performed.
void setCodeAreas (CTestBaseListSPtr &)
 Sets code areas for profiler.
virtual void setComment (int section, int idx, const std::string &nlComment, const std::string &eolComment)
void setDataAreas (CTestBaseListSPtr &)
 Sets data areas for profiler.
void setEnumTagValue (int section, int enumValue)
 Sets value of enum type.
void setExportActiveAreasOnly (iconnect::ETristate isExportActiveAreasOnly)
 If isExportActiveAreasOnly is true, then only areas with recorded activity (executed functions and modified data) will be exported.
void setExportFileName (const std::string &file)
 Sets format variant of the export format.
void setExportFormat (EProfilerExportFormat exportFormat)
 Sets format variant of the export format.
virtual void setMainMapStyle (isys::IEmitter::EYamlStyle mappingStyle)
 Sets style of the mapping for complete object.
void setMeasureAllFunctions (iconnect::ETristate isMeasureAllFunctions)
void setParent (CTestBaseSPtr parent)
 Sets parent.
void setProfileAUX (iconnect::ETristate isProfileAUX)
 If parameter is true, then AUX signals are recorded during profiling.
void setSaveHistory (iconnect::ETristate isSave)
 Sets the save mode for output file.
void swapAreas (EAreaType areaType, int idx1, int idx2)
 Swaps two areas in the list.
virtual std::string toString ()
 Returns object data as YAML string.

Static Public Member Functions

static CTestAnalyzerProfilerSPtr cast (CTestBaseSPtr &testBase)
 Casts the given object to this class.

Protected Member Functions

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

Detailed Description

This class contains specification for profiler recording during test execution.

 

Member Enumeration Documentation

◆ EAreaType

Profiler areas.

Enumerator
DATA_AREA 

profiler data area

CODE_AREA 

profiler code area

Constructor & Destructor Documentation

◆ CTestAnalyzerProfiler() [1/2]

isys::CTestAnalyzerProfiler::CTestAnalyzerProfiler ( )

Initializes new instance.

Since
9.12.288

◆ CTestAnalyzerProfiler() [2/2]

isys::CTestAnalyzerProfiler::CTestAnalyzerProfiler ( const CTestBaseSPtr & parent)

Initializes new instance.

Parameters
parentan instance of parent CTestSpecification class. Used only when parsing YAML declaration. Can be specified as NULL if the object is not initialized by parser.
Since
9.12.288

Member Function Documentation

◆ assign()

virtual void isys::CTestBase::assign ( const CTestObjectSPtr & base)
virtualinherited

Assigns members of base to this.

Since
9.12.288

Reimplemented in isys::CTestFunction.

◆ assignCodeAreas()

void isys::CTestAnalyzerProfiler::assignCodeAreas ( isys::CTestAnalyzerProfilerSPtr & src)

This method copies code areas from src to this object.

Since
9.12.288

◆ assignDataAreas()

void isys::CTestAnalyzerProfiler::assignDataAreas ( isys::CTestAnalyzerProfilerSPtr & src)

This method copies code areas from src to this object.

Since
9.12.288

◆ cast()

CTestAnalyzerProfilerSPtr isys::CTestAnalyzerProfiler::cast ( 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.

◆ containsSection()

bool isys::CTestBase::containsSection ( int section) const
inherited

Returns true, if the specified section exists for this object.

Since
9.12.288

◆ copy()

virtual CTestObjectSPtr isys::CTestBase::copy ( ) const
virtualinherited

Creates a deep copy of this object.

Parent is set.

Since
9.12.288

◆ createInstance()

CTestBaseSPtr isys::CTestAnalyzerProfiler::createInstance ( const CTestBaseSPtr & parent) const
virtual

Creates a new empty instance of this class.

Since
9.12.288

Implements isys::CTestBase.

◆ findArea() [1/2]

int isys::CTestAnalyzerProfiler::findArea ( const std::string & areaName,
const std::string & areaValue )

Returns index of the data area, or -1 if the area is not found.

This method searches for data areas with value set.

Since
9.12.288

◆ findArea() [2/2]

int isys::CTestAnalyzerProfiler::findArea ( EAreaType areaType,
const std::string & areaName )

Returns index of the area or -1 if the area is not found.

Parameters
areaTypeif set to DATA_AREA, then only data areas without value set can match.
areaName
Since
9.12.288

◆ getArea()

isys::CTestProfilerStatisticsSPtr isys::CTestAnalyzerProfiler::getArea ( EAreaType areaType,
int idx )

Returns the requested area.

Since
9.12.288

◆ getAreas()

CTestBaseListSPtr isys::CTestAnalyzerProfiler::getAreas ( EAreaType areaType,
bool isConst )

Returns areas of the given type.

Since
9.12.288

◆ getClassName()

std::string isys::CTestBase::getClassName ( ) const
inherited
Since
9.12.288

◆ getCodeAreas()

CTestBaseListSPtr isys::CTestAnalyzerProfiler::getCodeAreas ( bool isConst)

Returns code areas specified for profiler.

The returned list contains instances of CTestProfilerStatisticsSPtr.

Since
9.12.288

◆ getContainerTestNode()

virtual CTestTreeNodeSPtr isys::CTestBase::getContainerTestNode ( )
virtualinherited

virtual CTestSpecificationSPtr getContainerTestSpec();

Since
9.12.288

◆ getDataAreas()

CTestBaseListSPtr isys::CTestAnalyzerProfiler::getDataAreas ( bool isConst)

Returns code areas specified for profiler.

The returned list contains instances of CTestProfilerStatisticsSPtr.

Since
9.12.288

◆ getEnumTagValue()

int isys::CTestBase::getEnumTagValue ( int section)
inherited

Returns value of enum type.

Since
9.12.288

◆ getExportFileName()

std::string isys::CTestAnalyzerProfiler::getExportFileName ( )

Returns the export file name.

If empty, no export is performed.

Since
9.12.288

◆ getExportFormat()

EProfilerExportFormat isys::CTestAnalyzerProfiler::getExportFormat ( )

Returns the export format.

Empty string means XML format.

Since
9.12.288

◆ getParent()

CTestBaseSPtr isys::CTestBase::getParent ( ) const
inherited

Returns parent.

Since
9.12.288

◆ getSectionId()

int isys::CTestBase::getSectionId ( const std::string & sectionName)
inherited

Returns section ID for the given section name.

Since
9.12.288

◆ getTestBase()

CTestBaseSPtr isys::CTestBase::getTestBase ( int section,
bool isConst )
inherited
Since
9.12.288

◆ getTestBaseList()

CTestBaseListSPtr isys::CTestBase::getTestBaseList ( int section,
bool isConst )
inherited
Since
9.12.288

◆ getTestObjType()

CTestObject::ETestObjType isys::CTestBase::getTestObjType ( ) const
inherited

Returns type of this object, which is CTestObject::ETestBase.

Since
9.12.288

◆ isActive()

iconnect::ETristate isys::CTestAnalyzerProfiler::isActive ( )

Returns E_TRUE if this section is active (export is performed, and analysis is run for coverage and profiler).

Since
9.12.288

◆ isEmpty()

virtual bool isys::CTestBase::isEmpty ( ) const
virtualinherited

This method returns true, if the object contains no data.

Since
9.12.288

◆ isExportActiveAreasOnly()

iconnect::ETristate isys::CTestAnalyzerProfiler::isExportActiveAreasOnly ( )

Returns true, when only areas with recoded activity will be exported.

Returns false, if all configured areas will be exported.

Since
9.12.288

◆ isMeasureAllFunctions()

iconnect::ETristate isys::CTestAnalyzerProfiler::isMeasureAllFunctions ( )

Returns E_TRUE, if all functions should be measured, not only ones from code areas list.

If E_FALSE is returned, only functions from code areas list will be measured.

Since
9.12.288

◆ isMerged()

bool isys::CTestAnalyzerProfiler::isMerged ( ) const
virtual

Returns true, if the CTestSpecification section containing this object is merged.


Since
9.12.288

Reimplemented from isys::CTestBase.

◆ isProfileAUX()

iconnect::ETristate isys::CTestAnalyzerProfiler::isProfileAUX ( )

Returns true, if AUX signals should be recorded during profiler session.

Since
9.12.288

◆ isSaveHistory()

iconnect::ETristate isys::CTestAnalyzerProfiler::isSaveHistory ( )

Returns true, if profiler history should also be saved to output file.

Since
9.12.288

◆ isSectionEmpty()

bool isys::CTestBase::isSectionEmpty ( int sectionId)
inherited

Returns true, if the given section is empty.

Since
9.12.288

◆ isSerializedAsList()

virtual bool isys::CTestBase::isSerializedAsList ( bool isParsing)
virtualinherited

Returns true if object should be serialized as list, for example CTestFunction.

Since
9.12.288

Reimplemented in isys::CTestFunction.

◆ serialize()

virtual void isys::CTestBase::serialize ( const isys::IEmitterSPtr & emitter)
virtualinherited

Sends contents of this class to emitter.

Since
9.12.288

Reimplemented in isys::CLogResult, and isys::CTestEnvironmentConfig.

◆ setActive()

void isys::CTestAnalyzerProfiler::setActive ( iconnect::ETristate isActive)

If isActive == true, recording is exported and analysis is performed.

Since
9.12.288

◆ setCodeAreas()

void isys::CTestAnalyzerProfiler::setCodeAreas ( CTestBaseListSPtr & )

Sets code areas for profiler.

Since
9.12.288

◆ setComment()

virtual void isys::CTestBase::setComment ( int section,
int idx,
const std::string & nlComment,
const std::string & eolComment )
virtualinherited
Since
9.12.288

◆ setDataAreas()

void isys::CTestAnalyzerProfiler::setDataAreas ( CTestBaseListSPtr & )

Sets data areas for profiler.

Since
9.12.288

◆ setEnumTagValue()

void isys::CTestBase::setEnumTagValue ( int section,
int enumValue )
inherited

Sets value of enum type.

Since
9.12.288

◆ setExportActiveAreasOnly()

void isys::CTestAnalyzerProfiler::setExportActiveAreasOnly ( iconnect::ETristate isExportActiveAreasOnly)

If isExportActiveAreasOnly is true, then only areas with recorded activity (executed functions and modified data) will be exported.

Otherwise all configured areas will be exported.

Since
9.12.288

◆ setExportFileName()

void isys::CTestAnalyzerProfiler::setExportFileName ( const std::string & file)

Sets format variant of the export format.

Since
9.12.288

◆ setExportFormat()

void isys::CTestAnalyzerProfiler::setExportFormat ( EProfilerExportFormat exportFormat)

Sets format variant of the export format.

Since
9.12.288

◆ setMainMapStyle()

virtual void isys::CTestBase::setMainMapStyle ( isys::IEmitter::EYamlStyle mappingStyle)
virtualinherited

Sets style of the mapping for complete object.

Since
9.12.288

◆ setMeasureAllFunctions()

void isys::CTestAnalyzerProfiler::setMeasureAllFunctions ( iconnect::ETristate isMeasureAllFunctions)
Parameters
isMeasureAllFunctionsif E_TRUE, all functions should be measured, not only ones from code areas list. If E_FALSE, only functions from code areas list will be measured.
Since
9.12.288

◆ setParent()

void isys::CTestBase::setParent ( CTestBaseSPtr parent)
inherited

Sets parent.

Since
9.12.288

◆ setProfileAUX()

void isys::CTestAnalyzerProfiler::setProfileAUX ( iconnect::ETristate isProfileAUX)

If parameter is true, then AUX signals are recorded during profiling.

Since
9.12.288

◆ setSaveHistory()

void isys::CTestAnalyzerProfiler::setSaveHistory ( iconnect::ETristate isSave)

Sets the save mode for output file.

If true, history will also be saved.

Since
9.12.288

◆ swapAreas()

void isys::CTestAnalyzerProfiler::swapAreas ( EAreaType areaType,
int idx1,
int idx2 )

Swaps two areas in the list.

Since
9.12.288

◆ toString()

virtual std::string isys::CTestBase::toString ( )
virtualinherited

Returns object data as YAML string.

Since
9.12.288