12 #ifndef SST_CORE_STATAPI_STATNULL_H 13 #define SST_CORE_STATAPI_STATNULL_H 15 #include "sst/core/sst_types.h" 16 #include "sst/core/statapi/statbase.h" 17 #include "sst/core/warnmacros.h" 20 namespace Statistics {
38 template <class T, bool B = std::is_fundamental<T>::value>
47 BaseComponent* comp,
const std::string& statName,
const std::string& statSubId,
Params& statParams) :
51 this->setStatisticTypeName(
"NULL");
54 void addData_impl(T UNUSED(data))
override {}
56 void addData_impl_Ntimes(uint64_t UNUSED(N), T UNUSED(data))
override {}
59 template <
class... Args>
64 BaseComponent* comp,
const std::string& statName,
const std::string& statSubId,
Params& statParams) :
65 Statistic<std::tuple<Args...>>(comp, statName, statSubId, statParams)
68 this->setStatisticTypeName(
"NULL");
71 void addData_impl(Args... UNUSED(data))
override {}
73 void addData_impl_Ntimes(uint64_t UNUSED(N), Args... UNUSED(data))
override {}
81 BaseComponent* comp,
const std::string& statName,
const std::string& statSubId,
Params& statParams) :
85 this->setStatisticTypeName(
"NULL");
88 void addData_impl(T&& UNUSED(data))
override {}
89 void addData_impl(
const T& UNUSED(data))
override {}
91 void addData_impl(uint64_t UNUSED(N), T&& UNUSED(data))
override {}
92 void addData_impl(uint64_t UNUSED(N),
const T& UNUSED(data))
override {}
99 SST_ELI_DECLARE_STATISTIC_TEMPLATE(
103 SST_ELI_ELEMENT_VERSION(1,0,0),
104 "Null object it ignore all collections",
113 void clearStatisticData()
override 123 void outputStatisticFields(
StatisticFieldsOutput* UNUSED(statOutput),
bool UNUSED(EndOfSimFlag))
override 128 bool isReady()
const override {
return true; }
130 bool isNullStatistic()
const override {
return true; }
132 static bool isLoaded() {
return loaded_; }
144 SST_ELI_REGISTER_DERIVED(
149 SST_ELI_ELEMENT_VERSION(1,0,0),
150 "Null statistic for custom (void) stats" 153 SST_ELI_INTERFACE_INFO(
"Statistic<void>")
159 this->setStatisticTypeName(
"NULL");
166 #endif // SST_CORE_STATAPI_STATNULL_H Definition: statnull.h:142
Definition: statnull.h:39
Forms the template defined base class for statistics gathering within SST.
Definition: elementinfo.h:44
void Statistic has special meaning in that it does not collect fields in the usual way through the ad...
Definition: statbase.h:430
An empty statistic place holder.
Definition: statnull.h:96
Definition: statoutput.h:157
Main component object for the simulation.
Definition: baseComponent.h:51
Parameter store.
Definition: params.h:55