SST::Statistics::StatisticOutput Class Reference

Forms the base class for statistics output generation within the SST core. More...

#include <statoutput.h>

Inheritance diagram for SST::Statistics::StatisticOutput:
SST::Module SST::Statistics::StatisticOutputConsole SST::Statistics::StatisticOutputCSV SST::Statistics::StatisticOutputTxt

Public Types

typedef
StatisticFieldInfo::fieldType_t 
fieldType_t
typedef
StatisticFieldInfo::fieldHandle_t 
fieldHandle_t
typedef std::vector
< StatisticFieldInfo * > 
FieldInfoArray_t
typedef std::unordered_map
< std::string, fieldHandle_t > 
FieldNameMap_t

Public Member Functions

 StatisticOutput (Params &outputParameters)
 Construct a base StatisticOutput.
std::string & getStatisticOutputName ()
 Return the Statistic Output name.
uint8_t getStatisticLoadLevel ()
 Return the statistics load level for the system.
ParamsgetOutputParameters ()
 Return the parameters for the StatisticOutput.
template<typename T >
fieldHandle_t registerField (const char *fieldName)
 Register a field to be output (templated function).
StatisticFieldInfogetRegisteredField (fieldHandle_t fieldHandle)
 Adjust the heirarchy of the fields (FUTURE SUPPORT).
template<typename T >
StatisticFieldInfogetRegisteredField (const char *statisticName, const char *fieldName)
 Return the information on a registered field via known names.
FieldInfoArray_t & getFieldInfoArray ()
 Return the array of registered field infos.
void outputField (fieldHandle_t fieldHandle, int32_t data)
 Output field data.
void outputField (fieldHandle_t fieldHandle, uint32_t data)
void outputField (fieldHandle_t fieldHandle, int64_t data)
void outputField (fieldHandle_t fieldHandle, uint64_t data)
void outputField (fieldHandle_t fieldHandle, float data)
void outputField (fieldHandle_t fieldHandle, double data)
const char * getFieldTypeShortName (fieldType_t type)
 Output field data.

Protected Member Functions

virtual bool checkOutputParameters ()=0
 Have the Statistic Output check its parameters.
virtual void printUsage ()=0
 Have Statistic Object print out its usage and parameter info.
virtual void startOfSimulation ()=0
 Indicate to Statistic Output that simulation has started.
virtual void endOfSimulation ()=0
 Indicate to Statistic Output that simulation has ended.
virtual void implStartOutputEntries (StatisticBase *statistic)=0
 Indicate to Statistic Output that a statistic is about to send data to be output Allows object to perform any initialization before output.
virtual void implStopOutputEntries ()=0
 Indicate to Statistic Output that a statistic is finished sending data to be output Allows object to perform any cleanup.
virtual void implOutputField (fieldHandle_t fieldHandle, int32_t data)=0
 Implementation of outputField() for derived classes.
virtual void implOutputField (fieldHandle_t fieldHandle, uint32_t data)=0
virtual void implOutputField (fieldHandle_t fieldHandle, int64_t data)=0
virtual void implOutputField (fieldHandle_t fieldHandle, uint64_t data)=0
virtual void implOutputField (fieldHandle_t fieldHandle, float data)=0
virtual void implOutputField (fieldHandle_t fieldHandle, double data)=0
void setStatisticOutputName (std::string name)

Friends

class SST::Component
class SST::Simulation
class SST::Statistics::StatisticProcessingEngine
class boost::serialization::access

Detailed Description

Forms the base class for statistics output generation within the SST core.

Statistics are gathered by the statistic objects and then processed sent to the derived output object either periodically or by event and/or also at the end of the simuation. A single statistic output will be created by the simuation (per node) and will collect the data per its design.


Constructor & Destructor Documentation

SST::Statistics::StatisticOutput::StatisticOutput ( Params outputParameters  ) 

Construct a base StatisticOutput.

Parameters:
outputParameters - The parameters for the statistic Output.

Member Function Documentation

virtual bool SST::Statistics::StatisticOutput::checkOutputParameters (  )  [protected, pure virtual]

Have the Statistic Output check its parameters.

Returns:
True if all parameters are ok; False if a parameter is missing or incorrect.

Implemented in SST::Statistics::StatisticOutputConsole, SST::Statistics::StatisticOutputCSV, and SST::Statistics::StatisticOutputTxt.

Referenced by SST::Simulation::performWireUp().

virtual void SST::Statistics::StatisticOutput::endOfSimulation (  )  [protected, pure virtual]

Indicate to Statistic Output that simulation has ended.

Allows object to perform any shutdown required.

Implemented in SST::Statistics::StatisticOutputConsole, SST::Statistics::StatisticOutputCSV, and SST::Statistics::StatisticOutputTxt.

Referenced by SST::Simulation::run().

FieldInfoArray_t& SST::Statistics::StatisticOutput::getFieldInfoArray (  )  [inline]
const char * SST::Statistics::StatisticOutput::getFieldTypeShortName ( fieldType_t  type  ) 

Output field data.

Parameters:
type - The field type to get name of.
Returns:
String name of the field type.

Referenced by SST::Statistics::StatisticOutputTxt::implOutputField(), SST::Statistics::StatisticOutputConsole::implOutputField(), and SST::Statistics::StatisticOutputCSV::startOfSimulation().

template<typename T >
StatisticFieldInfo* SST::Statistics::StatisticOutput::getRegisteredField ( const char *  statisticName,
const char *  fieldName 
) [inline]

Return the information on a registered field via known names.

Parameters:
componentName - The name of the component.
statisticName - The name of the statistic.
fieldName - The name of the field .
Returns:
Pointer to the registered field info.

References SST::Statistics::StatisticFieldInfo::getFieldUniqueName().

StatisticFieldInfo * SST::Statistics::StatisticOutput::getRegisteredField ( fieldHandle_t  fieldHandle  ) 

Adjust the heirarchy of the fields (FUTURE SUPPORT).

Parameters:
fieldHandle - The handle of the field to adjust.
Level - The level of the field.
parent - The parent field of the field. Return the information on a registered field via the field handle.
fieldHandle - The handle of the registered field.
Returns:
Pointer to the registered field info.

Referenced by SST::Statistics::StatisticOutputTxt::implOutputField(), and SST::Statistics::StatisticOutputConsole::implOutputField().

virtual void SST::Statistics::StatisticOutput::implOutputField ( fieldHandle_t  fieldHandle,
int32_t  data 
) [protected, pure virtual]

Implementation of outputField() for derived classes.

Perform the actual implementation of the output.

Implemented in SST::Statistics::StatisticOutputConsole, SST::Statistics::StatisticOutputCSV, and SST::Statistics::StatisticOutputTxt.

Referenced by outputField().

virtual void SST::Statistics::StatisticOutput::implStartOutputEntries ( StatisticBase statistic  )  [protected, pure virtual]

Indicate to Statistic Output that a statistic is about to send data to be output Allows object to perform any initialization before output.

Implemented in SST::Statistics::StatisticOutputConsole, SST::Statistics::StatisticOutputCSV, and SST::Statistics::StatisticOutputTxt.

virtual void SST::Statistics::StatisticOutput::implStopOutputEntries (  )  [protected, pure virtual]

Indicate to Statistic Output that a statistic is finished sending data to be output Allows object to perform any cleanup.

Implemented in SST::Statistics::StatisticOutputConsole, SST::Statistics::StatisticOutputCSV, and SST::Statistics::StatisticOutputTxt.

void SST::Statistics::StatisticOutput::outputField ( fieldHandle_t  fieldHandle,
int32_t  data 
)

Output field data.

Parameters:
fieldHandle - The handle of the registered field.
data - The data to be output.

References implOutputField().

virtual void SST::Statistics::StatisticOutput::printUsage (  )  [protected, pure virtual]

Have Statistic Object print out its usage and parameter info.

Called when checkOutputParameters() returns false

Implemented in SST::Statistics::StatisticOutputConsole, SST::Statistics::StatisticOutputCSV, and SST::Statistics::StatisticOutputTxt.

Referenced by SST::Simulation::performWireUp().

template<typename T >
fieldHandle_t SST::Statistics::StatisticOutput::registerField ( const char *  fieldName  )  [inline]

Register a field to be output (templated function).

Parameters:
fieldName - The name of the field.
Returns:
The handle of the registerd field or -1 if type is not supported. Note: Any field names (of the same data type) that are previously registered by a statistic will return the previously handle.
virtual void SST::Statistics::StatisticOutput::startOfSimulation (  )  [protected, pure virtual]

Indicate to Statistic Output that simulation has started.

Allows object to perform any setup required.

Implemented in SST::Statistics::StatisticOutputConsole, SST::Statistics::StatisticOutputCSV, and SST::Statistics::StatisticOutputTxt.

Referenced by SST::Simulation::run().


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

Generated on 14 Sep 2015 for SST by  doxygen 1.6.1