9using TV = boost::property_tree::ptree::value_type;
31 for(
const auto & [monGroupName, monGroup] :
data().get_child(
"signatures" ) ) {
32 std::map<std::string, std::vector<std::string>> monGroupChainMap;
33 for(
const auto & [chainName, targetList] : monGroup) {
34 std::vector<std::string> monTarget{};
35 for(
const auto &
x: targetList) {
36 monTarget.push_back(
x.second.get_value<std::string>());
39 monGroupChainMap.emplace( chainName, monTarget);
44 catch(std::exception & ex) {
45 std::cerr <<
"ERROR: problem when building the HLT monitoring. " << ex.what() << std::endl;
50const std::set<std::string> &
55const std::map<std::string, std::map<std::string, std::vector<std::string>>> &
60std::vector<std::string>
62 std::vector<std::string> keys;
70std::vector<std::string>
72 std::vector<std::string> chains{};
75 chains.push_back(chain);
83 return data().get_child(
"signatures").size();
105 cout <<
"HLT monitoring '" <<
name() <<
"'" << endl;
106 cout <<
"Signatures: " <<
size() << endl;
107 cout <<
"Targets: " <<
targets().size() << endl;
109 cout <<
"Signatures: ";
111 size_t sigNameWidth(0);
119 sigNameWidth =
max(sigNameWidth,sigName.size());
121 cout << endl <<
"Targets: ";
123 std::vector<size_t> tnwidth{};
124 for(
auto & target :
targets() ) {
131 tnwidth.push_back(target.size());
135 cout <<
"Count of monitored chains by target:" << endl;
137 for(
auto & target :
targets() ) {
140 cout << setw(sigNameWidth+2) <<
"";
148 cout << setw(sigNameWidth) << left << sigName <<
": " << right;
151 for(
auto & target :
targets() ) {
char data[hepevt_bytes_allocation_ATLAS]
static const Attributes_t empty
virtual const std::string & name() const final
bool isInitialized() const
const ptree & data() const
Access to the underlying data, if needed.
DataStructure()
Default constructor, leading to an uninitialized configuration object.
T getAttribute(const std::string &key, bool ignoreIfMissing=false, const T &def=T()) const
Access to simple attribute.
const std::map< std::string, std::map< std::string, std::vector< std::string > > > & signatures() const
HLTMonitoring()
Constructor.
std::vector< std::string > signatureNames() const
names of the monitored signatures
unsigned int smk() const
setter and getter for the supermasterkey
virtual void clear() override
Clearing the configuration data.
unsigned int m_smk
the supermasterkey
std::size_t size() const
Accessor to the number of HLT monitoring chains.
void setSMK(unsigned int psk)
std::vector< std::string > chainsBySignatureAndTarget(const std::string &signature, const std::string &target) const
monitored chains by signature for a given target
void printMonConfig(bool full=false) const
print overview of L1 Menu
const std::set< std::string > & targets() const
names of targets
std::set< std::string > m_targets
names of monitoring targets like shifter, t0, online
std::map< std::string, std::map< std::string, std::vector< std::string > > > m_signatures
internal storage of the information
std::string find(const std::string &s)
return a remapped string