GemaCoreLib
The GeMA Core library
Loading...
Searching...
No Matches
gmPrintResultsRule.h
Go to the documentation of this file.
1/************************************************************************
2**
3** Copyright (C) 2014 by Carlos Augusto Teixera Mendes
4** All rights reserved.
5**
6** This file is part of the "GeMA" software. It's use should respect
7** the terms in the license agreement that can be found together
8** with this source code.
9** It is provided AS IS, with NO WARRANTY OF ANY KIND,
10** INCLUDING THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR
11** A PARTICULAR PURPOSE.
12**
13************************************************************************/
14
24#ifndef _GEMA_PRINT_RESULTS_RULE_H_
25#define _GEMA_PRINT_RESULTS_RULE_H_
26
27#include "gmResultsRule.h"
29
32{
33public:
34 virtual ~GmPrintResultsRule();
35
36 // See commets on the base class
37 virtual GmResultsRuleType type() const { return GM_RESULTS_PRINT_RULE; }
38
39 virtual void print(const GmLogCategory& logger, GmLogLevel level) const;
40
41 virtual bool run(const GmLogCategory& logger);
42
43 static GmPrintResultsRule* loadFromTable(const GmResultsData* data, LuaTable& tab,
44 const GmLogCategory& parseLogger, const GmSimulationData* simData);
45
46private:
47 Q_DISABLE_COPY(GmPrintResultsRule);
48
49 GmPrintResultsRule(QString id, QString description, const QVector<GmResultsDataSet*>& dataSets,
50 const QVector<GmResultsTimeSet*>& timeSets, bool trackObj, const GmSimulationData* simData);
51
52 void printAttributeData(const GmResultsDataSet* dataSet, const GmLogCategory& logger, GmLogLevel level) const;
53 void printEvalSetData (const GmResultsDataSet* dataSet, GmResultsDataSrcType type, const GmLogCategory& logger, GmLogLevel level) const;
54};
55
56
57#endif
Class representing a category with multiple logging levels.
Definition gmLog.h:58
A results rule printing the associated data sets to the logger.
Definition gmPrintResultsRule.h:32
virtual GmResultsRuleType type() const
Returns the result rule type.
Definition gmPrintResultsRule.h:37
Auxiliar class used to store the complete set of results data for a simulation.
Definition gmResultsData.h:58
A set storing what should be exported (saved / printed / monitored) by the result rule classes.
Definition gmResultsDataSet.h:58
A result rule represents an action that will be executed over one or more data sets at the moments (t...
Definition gmResultsRule.h:56
virtual void print(const GmLogCategory &logger, GmLogLevel level) const
Prints the rule description to the appointed logger / level.
Definition gmResultsRule.cpp:145
virtual bool run(const GmLogCategory &logger)=0
The virtual method responsible for executing this rule's actions.
Auxiliar class used to store the complete set of simulation data.
Definition gmSimulationData.h:55
#define GMC_API_EXPORT
Macro for controlling if the class is being exported (GEMA_CORE_LIB defined) or imported (GEMA_CORE_L...
Definition gmCoreConfig.h:35
GmLogLevel
Available log levels list.
Definition gmLog.h:36
Declaration of the GmResultsDataSrcInfo interface.
GmResultsDataSrcType
The types of data sources stored by a rule.
Definition gmResultsDataSrcInfo.h:33
Declaration of the GmResultsRule class.
GmResultsRuleType
The current available types for a result rule.
Definition gmResultsRule.h:41
@ GM_RESULTS_PRINT_RULE
A print rule.
Definition gmResultsRule.h:43