The Sparta Modeling Framework
Loading...
Searching...
No Matches
StatisticsStreams.hpp
1// <StatisticsStreams> -*- C++ -*-
2
3#pragma once
4
5#include "sparta/statistics/dispatch/StatisticsHierRootNodes.hpp"
6#include "sparta/statistics/dispatch/streams/StreamNode.hpp"
7
8namespace sparta {
9namespace statistics {
10
31{
32public:
37 void addHierarchyRoot(const std::string & storage_name,
38 std::shared_ptr<StreamNode> & root)
39 {
40 roots_.addHierarchyRoot(storage_name, root);
41 }
42
45 std::vector<std::string> getRootNames() const
46 {
47 return roots_.getRootNames();
48 }
49
54 void mapRootNameToReportFilename(const std::string & root_name,
55 const std::string & report_filename) const
56 {
57 roots_.mapRootNameToReportFilename(root_name, report_filename);
58 }
59
63 StreamNode * getRootByName(const std::string & root_name)
64 {
65 return roots_.getRootByName(root_name);
66 }
67
68private:
70};
71
72} // namespace statistics
73} // namespace sparta
74
Utility class that holds onto statistics node hierarchies, accessible by a name that you choose.
Wrapper around the StatisticsHierRootNodes<T> class. This class holds onto root StreamNode's that sit...
std::vector< std::string > getRootNames() const
void mapRootNameToReportFilename(const std::string &root_name, const std::string &report_filename) const
StreamNode * getRootByName(const std::string &root_name)
void addHierarchyRoot(const std::string &storage_name, std::shared_ptr< StreamNode > &root)
When a simulation is configured to stream its statistics values for asynchronous processing,...
Macros for handling exponential backoff.