SST 16.0.0
Structural Simulation Toolkit
statgroup.h
1// Copyright 2009-2026 NTESS. Under the terms
2// of Contract DE-NA0003525 with NTESS, the U.S.
3// Government retains certain rights in this software.
4//
5// Copyright (c) 2009-2026, NTESS
6// All rights reserved.
7//
8// This file is part of the SST software package. For license
9// information, see the LICENSE file in the top level directory of the
10// distribution.
11
12#ifndef SST_CORE_STATAPI_STATGROUP_H
13#define SST_CORE_STATAPI_STATGROUP_H
14
15#include "sst/core/serialization/serializer.h"
16#include "sst/core/sst_types.h"
17#include "sst/core/unitAlgebra.h"
18
19#include <cstddef>
20#include <string>
21#include <vector>
22
23namespace SST {
24class ConfigStatGroup;
25namespace Statistics {
26class StatisticBase;
27class StatisticOutput;
29
30/* A group of statistics that share a statistic output object*/
31class StatisticGroup
32{
33public:
34 StatisticGroup() {};
35 StatisticGroup(const ConfigStatGroup& csg, StatisticProcessingEngine* engine);
36 ~StatisticGroup();
37
38 bool containsStatistic(const StatisticBase* stat) const;
39 bool claimsStatistic(const StatisticBase* stat) const;
40 void addStatistic(StatisticBase* stat);
41
42 bool is_default = true;
43 std::string name = "default";
44 SimTime_t output_freq = 0;
45 StatisticOutput* output = nullptr;
46 size_t output_id = 0;
47
48
49 std::vector<ComponentId_t> components;
50 std::vector<std::string> stat_names;
51 std::vector<StatisticBase*> stats;
52
53 void restartGroup(StatisticProcessingEngine* engine);
54 void serialize_order(SST::Core::Serialization::serializer& ser);
55};
56
57} // namespace Statistics
58} // namespace SST
59
60#endif // SST_CORE_STATAPI_STATGROUP_H
Definition configStatistic.h:82
This class is basically a wrapper for objects to declare the order in which their members should be s...
Definition serializer.h:43
Forms the base class for statistics gathering within SST.
Definition statbase.h:51
Forms the base class for statistics output generation within the SST core.
Definition statoutput.h:54
An SST core component that handles timing and event processing informing all registered Statistics to...
Definition statengine.h:55