Manage collection of histograms, load histogram definitions from XML file and book histograms by calling MonitorObjectProvider routines. More...
#include <CSCDQM_Collection.h>
Public Types | |
typedef xercesc::DOMDocument | DOMDocument |
typedef xercesc::DOMElement | DOMElement |
typedef xercesc::DOMNamedNodeMap | DOMNamedNodeMap |
typedef xercesc::DOMNode | DOMNode |
typedef xercesc::DOMNodeList | DOMNodeList |
typedef xercesc::XercesDOMParser | XercesDOMParser |
typedef xercesc::XMLException | XMLException |
typedef xercesc::XMLPlatformUtils | XMLPlatformUtils |
typedef xercesc::XMLString | XMLString |
Public Member Functions | |
void | bookCSCHistos (const HwId crateId, const HwId dmbId) const |
Book Chamber Histograms. More... | |
void | bookCSCHistos (const HistoId hid, const HwId crateId, const HwId dmbId, const HwId addId) const |
Book Chamber Histogram with additional identifier (On Demand) More... | |
void | bookDDUHistos (const HwId dduId) const |
Book DDU histograms. More... | |
void | bookEMUHistos () const |
Book EMU histograms. More... | |
void | bookFEDHistos (const HwId fedId) const |
Book FED histograms. More... | |
Collection (Configuration *const p_config) | |
Constructor. More... | |
const bool | isOnDemand (const HistoName &name) const |
Check if the histogram is on demand (by histogram name) More... | |
void | load () |
Load XML file and fill definition map(s) More... | |
void | printCollection () const |
Print collection of available histograms and their parameters. More... | |
Private Member Functions | |
void | book (const HistoDef &h, const CoHistoProps &p, const std::string &folder) const |
Book histogram. More... | |
Static Private Member Functions | |
static const bool | checkHistoValue (const CoHistoProps &h, const std::string &name, std::string &value) |
Find string histogram value in map. More... | |
static const bool | checkHistoValue (const CoHistoProps &h, const std::string &name, int &value) |
get Histogram int value out of the map and return boolean result More... | |
static const bool | checkHistoValue (const CoHistoProps &h, const std::string name, double &value) |
get Histogram double value out of the map and return boolean result More... | |
static std::string & | getHistoValue (const CoHistoProps &h, const std::string &name, std::string &value, const std::string &def_value="") |
Find string histogram value in map. More... | |
static int & | getHistoValue (const CoHistoProps &h, const std::string &name, int &value, const int &def_value=0) |
get Histogram int value out of the map and More... | |
static double & | getHistoValue (const CoHistoProps &h, const std::string name, double &value, const int def_value=0.0) |
get Histogram double value out of the map and More... | |
static void | getNodeProperties (DOMNode *&node, CoHistoProps &hp) |
Extract and write single histogram properties from XML node to map. More... | |
static const int | ParseAxisLabels (const std::string &s, std::map< int, std::string > &labels) |
Parse Axis label string and return values in vector. More... | |
Private Attributes | |
CoHistoMap | collection |
Configuration * | config |
Manage collection of histograms, load histogram definitions from XML file and book histograms by calling MonitorObjectProvider routines.
Definition at line 73 of file CSCDQM_Collection.h.
typedef xercesc::DOMDocument cscdqm::Collection::DOMDocument |
Definition at line 76 of file CSCDQM_Collection.h.
typedef xercesc::DOMElement cscdqm::Collection::DOMElement |
Definition at line 77 of file CSCDQM_Collection.h.
typedef xercesc::DOMNamedNodeMap cscdqm::Collection::DOMNamedNodeMap |
Definition at line 80 of file CSCDQM_Collection.h.
typedef xercesc::DOMNode cscdqm::Collection::DOMNode |
Definition at line 78 of file CSCDQM_Collection.h.
typedef xercesc::DOMNodeList cscdqm::Collection::DOMNodeList |
Definition at line 79 of file CSCDQM_Collection.h.
typedef xercesc::XercesDOMParser cscdqm::Collection::XercesDOMParser |
Definition at line 84 of file CSCDQM_Collection.h.
typedef xercesc::XMLException cscdqm::Collection::XMLException |
Definition at line 81 of file CSCDQM_Collection.h.
typedef xercesc::XMLPlatformUtils cscdqm::Collection::XMLPlatformUtils |
Definition at line 83 of file CSCDQM_Collection.h.
typedef xercesc::XMLString cscdqm::Collection::XMLString |
Definition at line 82 of file CSCDQM_Collection.h.
cscdqm::Collection::Collection | ( | Configuration *const | p_config | ) |
Constructor.
p_config | Pointer to Global configuration object |
Definition at line 28 of file CSCDQM_Collection.cc.
References config.
|
private |
Book histogram.
h | Histogram definition to book |
p | Map of Histogram properties |
folder | folder to book histograms to |
Check if this histogram is included in booking by filters
Put histogram into cache
Definition at line 418 of file CSCDQM_Collection.cc.
References checkHistoValue(), config, cscdqm::DEF_HISTO_COLOR, edm::hlt::Exception, cscdqm::Configuration::fnBook, cscdqm::Configuration::fnPutHisto, cscdqm::HistoDef::getFullPath(), getHistoValue(), cscdqm::HistoDef::getName(), cscdqm::MonitorObject::getTH1Lock(), cscdqm::H1D, cscdqm::H2D, cscdqm::H3D, tablePrinter::labels, fff_deleter::lock(), LOG_INFO, cscdqm::Lock::mutex, mergeVDriftHistosByStation::name, cscdqm::Configuration::needBookMO(), NULL, ParseAxisLabels(), cscdqm::HistoDef::processTitle(), cscdqm::PROFILE, cscdqm::PROFILE2D, alignCSCRings::s, cscdqm::MonitorObject::setAxisTitle(), cscdqm::MonitorObject::SetMaximum(), AlCaHLTBitMon_QueryRunRegistry::string, indexGen::title, cscdqm::Utility::tokenize(), cscdqm::LockType::unlock(), findQualityFiles::v, cscdqm::XML_BOOK_HISTO_TITLE, cscdqm::XML_BOOK_HISTO_TYPE, cscdqm::XML_BOOK_ONDEMAND, cscdqm::XML_BOOK_ONDEMAND_FALSE, and cscdqm::XML_BOOK_ONDEMAND_TRUE.
Referenced by bookCSCHistos(), bookDDUHistos(), bookEMUHistos(), and bookFEDHistos().
Book Chamber Histograms.
crateId | CSC Crate Id |
dmbId | CSC DMB Id |
Definition at line 365 of file CSCDQM_Collection.cc.
References book(), checkHistoValue(), collection, config, cscdqm::HistoDef::getHistoIdByName(), getHistoValue(), i, j, gen::k, alignCSCRings::s, AlCaHLTBitMon_QueryRunRegistry::string, cscdqm::XML_BOOK_NAME_FROM, cscdqm::XML_BOOK_NAME_TO, cscdqm::XML_BOOK_ONDEMAND, and cscdqm::XML_BOOK_ONDEMAND_FALSE.
Referenced by cscdqm::Dispatcher::book(), and cscdqm::Dispatcher::getHisto().
void cscdqm::Collection::bookCSCHistos | ( | const HistoId | hid, |
const HwId | crateId, | ||
const HwId | dmbId, | ||
const HwId | addId | ||
) | const |
Book Chamber Histogram with additional identifier (On Demand)
hid | Histogram Identifier |
crateId | CSC Crate Id |
dmbId | CSC DMB Id |
addId | CSC Additional identifier, ex. Layer Id, ALCT Id, etc. |
Definition at line 400 of file CSCDQM_Collection.cc.
References book(), collection, config, i, j, and cscdqm::h::names.
void cscdqm::Collection::bookDDUHistos | ( | const HwId | dduId | ) | const |
Book DDU histograms.
dduId | DDU Id |
Definition at line 342 of file CSCDQM_Collection.cc.
References book(), collection, config, cscdqm::HistoDef::getHistoIdByName(), getHistoValue(), i, j, alignCSCRings::s, AlCaHLTBitMon_QueryRunRegistry::string, cscdqm::XML_BOOK_ONDEMAND, and cscdqm::XML_BOOK_ONDEMAND_FALSE.
Referenced by cscdqm::Dispatcher::book(), and cscdqm::Dispatcher::getHisto().
void cscdqm::Collection::bookEMUHistos | ( | ) | const |
Book EMU histograms.
Definition at line 298 of file CSCDQM_Collection.cc.
References book(), collection, config, cscdqm::HistoDef::getHistoIdByName(), getHistoValue(), i, j, alignCSCRings::s, AlCaHLTBitMon_QueryRunRegistry::string, cscdqm::XML_BOOK_ONDEMAND, and cscdqm::XML_BOOK_ONDEMAND_FALSE.
Referenced by cscdqm::Dispatcher::book().
void cscdqm::Collection::bookFEDHistos | ( | const HwId | fedId | ) | const |
Book FED histograms.
fedId | FED Id |
Definition at line 320 of file CSCDQM_Collection.cc.
References book(), collection, config, cscdqm::HistoDef::getHistoIdByName(), getHistoValue(), i, j, alignCSCRings::s, AlCaHLTBitMon_QueryRunRegistry::string, cscdqm::XML_BOOK_ONDEMAND, and cscdqm::XML_BOOK_ONDEMAND_FALSE.
Referenced by cscdqm::Dispatcher::book(), and cscdqm::Dispatcher::getHisto().
|
staticprivate |
Find string histogram value in map.
h | Histogram map |
name | parameter name |
value | handler for parameter value |
Definition at line 176 of file CSCDQM_Collection.cc.
References i.
Referenced by book(), bookCSCHistos(), and getHistoValue().
|
staticprivate |
get Histogram int value out of the map and return boolean result
h | Histogram map |
name | parameter name |
value | handler for parameter value |
Definition at line 192 of file CSCDQM_Collection.cc.
References i, and relativeConstraints::value.
|
staticprivate |
get Histogram double value out of the map and return boolean result
h | Histogram map |
name | parameter name |
value | handler for parameter value |
Definition at line 211 of file CSCDQM_Collection.cc.
References i, and relativeConstraints::value.
|
staticprivate |
Find string histogram value in map.
h | Histogram map |
name | parameter name |
value | handler for parameter value |
def_value | default value if parameter not found |
Definition at line 230 of file CSCDQM_Collection.cc.
References checkHistoValue(), and relativeConstraints::value.
Referenced by book(), bookCSCHistos(), bookDDUHistos(), bookEMUHistos(), bookFEDHistos(), and isOnDemand().
|
staticprivate |
get Histogram int value out of the map and
h | Histogram map |
name | parameter name |
value | handler for parameter value |
def_value | default value if parameter not found |
Definition at line 245 of file CSCDQM_Collection.cc.
References checkHistoValue(), and relativeConstraints::value.
|
staticprivate |
get Histogram double value out of the map and
h | Histogram map |
name | parameter name |
value | handler for parameter value |
def_value | default value if parameter not found |
Definition at line 260 of file CSCDQM_Collection.cc.
References checkHistoValue(), and relativeConstraints::value.
|
staticprivate |
Extract and write single histogram properties from XML node to map.
node | XML node |
p | List of properties to fill |
Definition at line 149 of file CSCDQM_Collection.cc.
References asciidump::attributes, i, j, mergeVDriftHistosByStation::name, AlCaHLTBitMon_QueryRunRegistry::string, and relativeConstraints::value.
Referenced by load().
const bool cscdqm::Collection::isOnDemand | ( | const HistoName & | name | ) | const |
Check if the histogram is on demand (by histogram name)
name | name of the histogram |
Definition at line 597 of file CSCDQM_Collection.cc.
References collection, getHistoValue(), i, j, alignCSCRings::s, AlCaHLTBitMon_QueryRunRegistry::string, cscdqm::XML_BOOK_ONDEMAND, cscdqm::XML_BOOK_ONDEMAND_FALSE, and cscdqm::XML_BOOK_ONDEMAND_TRUE.
Referenced by cscdqm::Dispatcher::getHisto().
void cscdqm::Collection::load | ( | ) |
Load XML file and fill definition map(s)
Load histogram definition
Load histogram
Definition at line 37 of file CSCDQM_Collection.cc.
References collection, config, asciidump::doc, reco::dp, alignCSCRings::e, edm::hlt::Exception, getNodeProperties(), h, AnalysisDataFormats_SUSYBSMObjects::hp, i, LOG_INFO, python.rootplot.argparse::message, mergeVDriftHistosByStation::name, python.Node::node, geometryXMLtoCSV::parser, prof2calltree::prefix, cscdqm::Utility::regexMatch(), cscdqm::REGEXP_ONDEMAND(), AlCaHLTBitMon_QueryRunRegistry::string, cms::concurrency::xercesInitialize(), cms::concurrency::xercesTerminate(), cscdqm::XML_BOOK_DEFINITION, cscdqm::XML_BOOK_DEFINITION_ID, cscdqm::XML_BOOK_DEFINITION_REF, cscdqm::XML_BOOK_HISTO_NAME, cscdqm::XML_BOOK_HISTO_PREFIX, cscdqm::XML_BOOK_HISTOGRAM, cscdqm::XML_BOOK_ONDEMAND, cscdqm::XML_BOOK_ONDEMAND_FALSE, and cscdqm::XML_BOOK_ONDEMAND_TRUE.
Referenced by cscdqm::Dispatcher::init().
|
staticprivate |
Parse Axis label string and return values in vector.
s | source string to parse |
labels | pointer to result vector |
Definition at line 273 of file CSCDQM_Collection.cc.
References diffTwoXMLs::label, NULL, alignCSCRings::s, AlCaHLTBitMon_QueryRunRegistry::string, and tmp.
Referenced by book().
void cscdqm::Collection::printCollection | ( | ) | const |
Print collection of available histograms and their parameters.
Definition at line 614 of file CSCDQM_Collection.cc.
References collection, and LOG_INFO.
|
private |
Definition at line 113 of file CSCDQM_Collection.h.
Referenced by bookCSCHistos(), bookDDUHistos(), bookEMUHistos(), bookFEDHistos(), isOnDemand(), load(), and printCollection().
|
private |
Definition at line 112 of file CSCDQM_Collection.h.
Referenced by book(), bookCSCHistos(), bookDDUHistos(), bookEMUHistos(), bookFEDHistos(), Collection(), and load().