ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Trigger
TrigConfiguration
TrigConfL1Data
Root
PrioritySet.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#include "
TrigConfL1Data/PrioritySet.h
"
6
#include <iostream>
7
8
9
using namespace
std
;
10
11
TrigConf::PrioritySet::PrioritySet
()
12
:
L1DataBaseclass
(),
m_Priorities
(
N_PRIORITIES
,
"LOW"
)
13
{}
14
15
void
16
TrigConf::PrioritySet::setPriorities
(
const
std::vector<std::string>&
vec
) {
17
if
(
vec
.size() >
N_PRIORITIES
) std::cerr
18
<<
"setPriorities >> number of priorities too high: "
<<
vec
.size() << std::endl;
19
for
(
unsigned
int
i=0; i<
vec
.size(); ++i)
m_Priorities
.at(i) =
vec
[i];
20
}
21
22
void
23
TrigConf::PrioritySet::print
(
const
std::string&
indent
,
unsigned
int
detail
)
const
{
24
if
(
detail
>=5) {
25
cout <<
indent
<<
"PrioritySet "
<<
name
() << endl;
26
cout <<
indent
<<
"lvl1MasterTableId: "
<<
lvl1MasterTableId
() << endl;
27
unsigned
int
ctpid(0);
28
for
(
const
string
& priority:
m_Priorities
)
29
cout <<
"\t "
<< ctpid++ <<
"\t"
<<
" priority = "
<< priority << endl;
30
}
31
}
32
33
37
void
38
TrigConf::PrioritySet::writeXML
(std::ostream &
xmlfile
,
int
indentLevel,
int
indentWidth)
const
{
39
indent
(
xmlfile
, indentLevel, indentWidth)
40
<<
"<PrioritySet name=\""
<<
name
() <<
"\" version=\""
<<
version
() <<
"\">"
41
<< endl;
42
unsigned
int
ctpid(0);
43
for
(
const
string
& priority :
m_Priorities
) {
44
indent
(
xmlfile
, indentLevel + 1, indentWidth)
45
<<
"<Priority ctpid=\""
<< ctpid++
46
<<
"\" priority=\""
<< priority <<
"\">"
47
<< priority <<
"</Priority>"
<< endl;
48
}
49
indent
(
xmlfile
, indentLevel, indentWidth)
50
<<
"</PrioritySet>"
<< endl;
51
}
52
vec
std::vector< size_t > vec
Definition
CombinationsGeneratorTest.cxx:9
PrioritySet.h
TrigConf::L1DataBaseclass::L1DataBaseclass
L1DataBaseclass()
Definition
L1DataBaseclass.h:24
TrigConf::L1DataBaseclass::lvl1MasterTableId
unsigned int lvl1MasterTableId() const
Definition
L1DataBaseclass.h:30
TrigConf::PrioritySet::N_PRIORITIES
static const unsigned int N_PRIORITIES
Definition
PrioritySet.h:18
TrigConf::PrioritySet::writeXML
virtual void writeXML(std::ostream &xmlfile, int indentLevel=0, int indentWidth=2) const
Writes the Prescale item to the XML file.
Definition
PrioritySet.cxx:38
TrigConf::PrioritySet::print
virtual void print(const std::string &indent="", unsigned int detail=1) const override
Definition
PrioritySet.cxx:23
TrigConf::PrioritySet::m_Priorities
std::vector< std::string > m_Priorities
Definition
PrioritySet.h:32
TrigConf::PrioritySet::PrioritySet
PrioritySet()
Definition
PrioritySet.cxx:11
TrigConf::PrioritySet::setPriorities
void setPriorities(const std::vector< std::string > &vec)
Definition
PrioritySet.cxx:16
TrigConf::TrigConfData::indent
std::ostream & indent(std::ostream &o, int lvl, int size) const
Definition
TrigConfData.cxx:23
TrigConf::TrigConfData::version
unsigned int version() const
Definition
TrigConfData.h:24
xmlfile
static std::vector< std::string > xmlfile
Definition
iLumiCalc.h:29
detail
Definition
extract_histogram_tag.cxx:14
std
STL namespace.
TrigConf::name
Definition
HLTChainList.h:35
Generated on
for ATLAS Offline Software by
1.17.0