CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes
egHLT::MonElemContainer< T > Class Template Reference

#include <EgHLTMonElemContainer.h>

Inheritance diagram for egHLT::MonElemContainer< T >:
egHLT::MonElemWithCutBase< T >

Public Member Functions

std::vector< MonElemWithCutBase< T > * > & cutMonElems ()
 
const std::vector< MonElemWithCutBase< T > * > & cutMonElems () const
 
void fill (const T &obj, const OffEvt &evt, float weight) override
 
 MonElemContainer (std::string baseName="", std::string baseTitle="", EgHLTDQMCut< T > *cut=nullptr)
 
std::vector< MonElemManagerBase< T > * > & monElems ()
 
const std::vector< MonElemManagerBase< T > * > & monElems () const
 
const std::string & name () const
 
const std::string & title () const
 
 ~MonElemContainer () override
 
- Public Member Functions inherited from egHLT::MonElemWithCutBase< T >
 MonElemWithCutBase ()=default
 
virtual ~MonElemWithCutBase ()=default
 

Private Member Functions

 MonElemContainer (const MonElemContainer &rhs)
 
MonElemContaineroperator= (const MonElemContainer &rhs)
 

Private Attributes

std::string baseName_
 
std::string baseTitle_
 
EgHLTDQMCut< T > * cut_
 
std::vector< MonElemWithCutBase< T > * > cutMonElems_
 
std::vector< MonElemManagerBase< T > * > monElems_
 

Detailed Description

template<class T>
class egHLT::MonElemContainer< T >

Definition at line 28 of file EgHLTMonElemContainer.h.

Constructor & Destructor Documentation

◆ MonElemContainer() [1/2]

template<class T>
egHLT::MonElemContainer< T >::MonElemContainer ( const MonElemContainer< T > &  rhs)
inlineprivate

Definition at line 40 of file EgHLTMonElemContainer.h.

40 {}

◆ MonElemContainer() [2/2]

template<class T>
egHLT::MonElemContainer< T >::MonElemContainer ( std::string  baseName = "",
std::string  baseTitle = "",
EgHLTDQMCut< T > *  cut = nullptr 
)
inline

Definition at line 44 of file EgHLTMonElemContainer.h.

45  : baseName_(std::move(baseName)), baseTitle_(std::move(baseTitle)), cut_(cut) {}

◆ ~MonElemContainer()

template<class T >
egHLT::MonElemContainer< T >::~MonElemContainer ( )
override

Definition at line 62 of file EgHLTMonElemContainer.h.

62  {
63  for (size_t i = 0; i < monElems_.size(); i++)
64  delete monElems_[i];
65  for (size_t i = 0; i < cutMonElems_.size(); i++)
66  delete cutMonElems_[i];
67  if (cut_ != nullptr)
68  delete cut_;
69  }

References mps_fire::i.

Member Function Documentation

◆ cutMonElems() [1/2]

template<class T>
std::vector<MonElemWithCutBase<T>*>& egHLT::MonElemContainer< T >::cutMonElems ( )
inline

◆ cutMonElems() [2/2]

template<class T>
const std::vector<MonElemWithCutBase<T>*>& egHLT::MonElemContainer< T >::cutMonElems ( ) const
inline

Definition at line 51 of file EgHLTMonElemContainer.h.

51 { return cutMonElems_; }

References egHLT::MonElemContainer< T >::cutMonElems_.

◆ fill()

template<class T >
void egHLT::MonElemContainer< T >::fill ( const T obj,
const OffEvt evt,
float  weight 
)
overridevirtual

Implements egHLT::MonElemWithCutBase< T >.

Definition at line 72 of file EgHLTMonElemContainer.h.

72  {
73  if (cut_ == nullptr || cut_->pass(obj, evt)) {
74  for (size_t i = 0; i < monElems_.size(); i++)
76  for (size_t i = 0; i < cutMonElems_.size(); i++)
77  cutMonElems_[i]->fill(obj, evt, weight);
78  }
79  }

References ntuplemaker::fill, mps_fire::i, and getGTfromDQMFile::obj.

◆ monElems() [1/2]

template<class T>
std::vector<MonElemManagerBase<T>*>& egHLT::MonElemContainer< T >::monElems ( )
inline

◆ monElems() [2/2]

template<class T>
const std::vector<MonElemManagerBase<T>*>& egHLT::MonElemContainer< T >::monElems ( ) const
inline

Definition at line 53 of file EgHLTMonElemContainer.h.

53 { return monElems_; }

References egHLT::MonElemContainer< T >::monElems_.

◆ name()

template<class T>
const std::string& egHLT::MonElemContainer< T >::name ( void  ) const
inline

◆ operator=()

template<class T>
MonElemContainer& egHLT::MonElemContainer< T >::operator= ( const MonElemContainer< T > &  rhs)
inlineprivate

Definition at line 41 of file EgHLTMonElemContainer.h.

41 { return *this; }

◆ title()

template<class T>
const std::string& egHLT::MonElemContainer< T >::title ( ) const
inline

Definition at line 56 of file EgHLTMonElemContainer.h.

56 { return baseTitle_; }

References egHLT::MonElemContainer< T >::baseTitle_.

Member Data Documentation

◆ baseName_

template<class T>
std::string egHLT::MonElemContainer< T >::baseName_
private

Definition at line 30 of file EgHLTMonElemContainer.h.

Referenced by egHLT::MonElemContainer< T >::name().

◆ baseTitle_

template<class T>
std::string egHLT::MonElemContainer< T >::baseTitle_
private

Definition at line 31 of file EgHLTMonElemContainer.h.

Referenced by egHLT::MonElemContainer< T >::title().

◆ cut_

template<class T>
EgHLTDQMCut<T>* egHLT::MonElemContainer< T >::cut_
private

Definition at line 37 of file EgHLTMonElemContainer.h.

◆ cutMonElems_

template<class T>
std::vector<MonElemWithCutBase<T>*> egHLT::MonElemContainer< T >::cutMonElems_
private

Definition at line 35 of file EgHLTMonElemContainer.h.

Referenced by egHLT::MonElemContainer< T >::cutMonElems().

◆ monElems_

template<class T>
std::vector<MonElemManagerBase<T>*> egHLT::MonElemContainer< T >::monElems_
private

Definition at line 36 of file EgHLTMonElemContainer.h.

Referenced by egHLT::MonElemContainer< T >::monElems().

mps_fire.i
i
Definition: mps_fire.py:355
TkAlMuonSelectors_cfi.cut
cut
Definition: TkAlMuonSelectors_cfi.py:5
egHLT::MonElemContainer::baseName_
std::string baseName_
Definition: EgHLTMonElemContainer.h:30
egHLT::MonElemContainer::monElems_
std::vector< MonElemManagerBase< T > * > monElems_
Definition: EgHLTMonElemContainer.h:36
getGTfromDQMFile.obj
obj
Definition: getGTfromDQMFile.py:32
egHLT::MonElemContainer::fill
void fill(const T &obj, const OffEvt &evt, float weight) override
Definition: EgHLTMonElemContainer.h:72
eostools.move
def move(src, dest)
Definition: eostools.py:511
egHLT::MonElemContainer::cut_
EgHLTDQMCut< T > * cut_
Definition: EgHLTMonElemContainer.h:37
egHLT::MonElemContainer::baseTitle_
std::string baseTitle_
Definition: EgHLTMonElemContainer.h:31
egHLT::MonElemContainer::cutMonElems_
std::vector< MonElemWithCutBase< T > * > cutMonElems_
Definition: EgHLTMonElemContainer.h:35
weight
Definition: weight.py:1