ATLAS Offline Software
ThresholdMonitor.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3 */
4 
13 
14 #include <stdexcept>
15 #include <iostream>
16 
17 using namespace std;
18 
21 {}
22 
25  m_CounterType(mon.m_CounterType),
26  m_ThresholdName(mon.m_ThresholdName),
27  m_CtpinSlot(mon.m_CtpinSlot),
28  m_CtpinConnector(mon.m_CtpinConnector),
29  m_ThresholdId(mon.m_ThresholdId),
30  m_BunchGroupId(mon.m_BunchGroupId),
31  m_Multiplicity(mon.m_Multiplicity),
32  m_InternalCounter(mon.m_InternalCounter),
33  m_ThresholdStartBit(mon.m_ThresholdStartBit),
34  m_ThresholdEndBit(mon.m_ThresholdEndBit),
35  m_ThresholdActive(mon.m_ThresholdActive)
36 {
37  setName(mon.name());
38  setVersion(mon.version());
39 }
40 
41 void
42 TrigConf::ThresholdMonitor::print(const std::string& indent, unsigned int detail) const {
43  if(detail==3) {
44  cout << indent << "Monitor Counter : " << name() << " (id=" << m_InternalCounter << ")" << endl;
45  }
46  if(detail>=4) {
47  cout << indent << "==================================" << endl;
48  cout << indent << "Monitor Counter : " << name() << " (id=" << m_InternalCounter << ")" << endl;
49  cout << indent << "monitors " << m_CounterType << " threshold " << m_ThresholdName << " (id=" << m_ThresholdId << ") with multiplicity " << m_Multiplicity << endl;
50  cout << indent << "Slot " << m_CtpinSlot << ", connector " << m_CtpinConnector << ", bits " << m_ThresholdStartBit << " - " << m_ThresholdEndBit << ", bunch group " << m_BunchGroupId << endl;
51  }
52 
53 }
54 
55 
56 void
57 TrigConf::ThresholdMonitor::writeXML(std::ostream & xmlfile, int indentLevel, int indentWidth) const {
58  indent(xmlfile, indentLevel, indentWidth) << "<TriggerCounter name=\"" << name() << "\" type=\"CTPIN\">" << endl;
59  indent(xmlfile, indentLevel+1, indentWidth) << "<TriggerCondition name=\"" << name() << "\" triggerthreshold=\"" << m_ThresholdName << "\" multi=\"" << m_Multiplicity << "\"/>" << endl;
60  indent(xmlfile, indentLevel, indentWidth) << "</TriggerCounter>" << endl;
61 }
TrigConf::TrigConfData::setName
void setName(const std::string &name)
Definition: TrigConfData.h:30
detail
Definition: extract_histogram_tag.cxx:14
TrigConf::ThresholdMonitor::writeXML
virtual void writeXML(std::ostream &xmlfile, int indentLevel=0, int indentWidth=2) const
Definition: ThresholdMonitor.cxx:57
ThresholdMonitor.h
TrigConf::ThresholdMonitor::print
virtual void print(const std::string &indent="", unsigned int detail=1) const override
Definition: ThresholdMonitor.cxx:42
TrigConf::ThresholdMonitor
Definition: ThresholdMonitor.h:18
MuonThresholdValue.h
geometry_dat_to_json.indent
indent
Definition: geometry_dat_to_json.py:18
CaloInfo.h
JetThresholdValue.h
TrigConf::ThresholdMonitor::ThresholdMonitor
ThresholdMonitor()
Definition: ThresholdMonitor.cxx:19
NimThresholdValue.h
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:195
L1DataDef.h
EtThresholdValue.h
ClusterThresholdValue.h
plotBeamSpotMon.mon
mon
Definition: plotBeamSpotMon.py:67
TrigConf::TrigConfData::setVersion
void setVersion(unsigned int version)
Definition: TrigConfData.h:31
TrigConf::L1DataBaseclass
Definition: L1DataBaseclass.h:22