Go to the documentation of this file.
17 #include <nlohmann/json.hpp>
37 .orThrow(
"Unable to set typesToSaveProperty",
"Histograming::Sink::Base" );
41 return BaseSink::initialize().
andThen( [&] {
57 for (
auto& [
name,
j] : entityMap ) {
58 auto dim =
j.at(
"dimension" ).template get<unsigned int>();
59 auto type =
j.at(
"type" ).template get<std::string>();
79 "Name of file where to save histograms" };
Gaudi::Property< std::string > m_fileName
Base class for all Sinks registering to the Monitoring Hub Should be extended by actual Sinks.
StatusCode andThen(F &&f, ARGS &&... args) const
Chain code blocks making the execution conditional a success result.
StatusCode setProperty(const Gaudi::Details::PropertyBase &p)
Set the property from a property.
StatusCode initialize() override
void flush(bool) override
pure virtual method to be defined by children and responsible for flushing current data of the Sink.
const std::string & name() const override
Retrieve name of the service
void registerHandler(HistoIdentification const &id, HistoHandler const &func)
const ValueType & value() const
MsgStream & endmsg(MsgStream &s)
MsgStream Modifier: endmsg. Calls the output method of the MsgStream.
HistoRegistry m_registry
map of supported type and the way to handle them
Base(std::string name, ISvcLocator *svcloc)
std::map< std::string, std::map< std::string, nlohmann::json > > sortedEntitiesAsJSON() const
returns all entities in JSON format, grouped by component first and then name