ATLAS Offline Software
Loading...
Searching...
No Matches
HLTChainList.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef TrigConf_HLTChainList
6#define TrigConf_HLTChainList
7
8#include <string>
9#include <iosfwd>
10#include <vector>
11
13
14#include <boost/multi_index_container.hpp>
15#include <boost/multi_index/mem_fun.hpp>
16#include <boost/multi_index/hashed_index.hpp>
17#include <boost/multi_index/ordered_index.hpp>
18#include <boost/multi_index/random_access_index.hpp>
19#include <boost/multi_index/composite_key.hpp>
20
21/* @brief class to hold the chains
22 *
23 * The chains are owned by this collection
24 */
25namespace TrigConf {
26
27 class HLTChainList;
28 class CTPConfig;
29 class HLTPrescaleSet;
30 class DiffStruct;
31
32 std::ostream & operator<<(std::ostream &, const TrigConf::HLTChainList &);
33
34 // dummy classes to work as indeces for boost::multi_index structure
35 struct name{};
36 struct name_hash{};
37 struct counter{};
38
39 typedef boost::multi_index::multi_index_container<HLTChain*, boost::multi_index::indexed_by<
40 boost::multi_index::ordered_unique< boost::multi_index::identity<HLTChain> >,
41 boost::multi_index::ordered_unique< boost::multi_index::tag<counter>,
42 boost::multi_index::composite_key<
43 HLTChain*,
44 boost::multi_index::const_mem_fun<HLTChain,int,&HLTChain::chain_counter>,
45 boost::multi_index::const_mem_fun<HLTChain,HLTLevel,&HLTChain::level_enum>
46 >
47 >,
48 boost::multi_index::ordered_unique< boost::multi_index::tag<name>, boost::multi_index::const_mem_fun<HLTChain, const std::string&, &HLTChain::chain_name> >,
49 boost::multi_index::hashed_unique< boost::multi_index::tag<name_hash>, boost::multi_index::const_mem_fun<HLTChain,const std::string&, &HLTChain::chain_name> >,
50 boost::multi_index::random_access<>
51 >
53
54
57 public:
58
60 HLTChainList();
61
66 HLTChainList( const std::vector<HLTChain*>& chainList );
67
70
75 bool addHLTChain(HLTChain* ch);
76
80 HLTChain* chain( const std::string& chainname ) const;
81
86 HLTChain* chain( unsigned int counter, HLTLevel level ) const;
87
89 //std::vector<HLTChain*> chains() const;
90
92 void print(const std::string& indent="", unsigned int detail=1) const;
93
94 DiffStruct* compareTo(const HLTChainList* o) const;
95
97 void applyPrescaleSet(const HLTPrescaleSet* pss);
98
101
102 void setL2LowerChainCounter(const CTPConfig* ctpcfg);
103
105
106 // delete all chains and clear the container
107 void clear();
108
109 friend std::ostream & operator<<(std::ostream & o, const TrigConf::HLTChainList & c);
110 };
111
112}
113
114#endif
115
list of all HLT chains in a trigger menu
bool addHLTChain(HLTChain *ch)
adds an HLTChain to the menu
void setL2LowerChainCounter(const CTPConfig *ctpcfg)
HLTChain * chain(const std::string &chainname) const
access the chain by name returns null-pointer if chain not found
HLTChainList()
default constructor
void applyPrescaleSet(const HLTPrescaleSet *pss)
set prescales of all chains
void print(const std::string &indent="", unsigned int detail=1) const
accessors to list of chains, for backward compatibility, use HLTChainList directly
~HLTChainList()
default destructor
DiffStruct * compareTo(const HLTChainList *o) const
friend std::ostream & operator<<(std::ostream &o, const TrigConf::HLTChainList &c)
HLTPrescaleSet * extractPrescaleSet() const
extract prescales from all chains
HLT chain configuration information.
HLT chain configuration information.
Forward iterator to traverse the main components of the trigger configuration.
Definition Config.h:22
std::ostream & operator<<(std::ostream &os, const TrigConf::IsolationLegacy &iso)
boost::multi_index::multi_index_container< HLTChain *, boost::multi_index::indexed_by< boost::multi_index::ordered_unique< boost::multi_index::identity< HLTChain > >, boost::multi_index::ordered_unique< boost::multi_index::tag< counter >, boost::multi_index::composite_key< HLTChain *, boost::multi_index::const_mem_fun< HLTChain, int,&HLTChain::chain_counter >, boost::multi_index::const_mem_fun< HLTChain, HLTLevel,&HLTChain::level_enum > > >, boost::multi_index::ordered_unique< boost::multi_index::tag< name >, boost::multi_index::const_mem_fun< HLTChain, const std::string &, &HLTChain::chain_name > >, boost::multi_index::hashed_unique< boost::multi_index::tag< name_hash >, boost::multi_index::const_mem_fun< HLTChain, const std::string &, &HLTChain::chain_name > >, boost::multi_index::random_access<> > > HLTChainContainer