CMS 3D CMS Logo

List of all members | Public Member Functions | Protected Member Functions | Protected Attributes | Private Attributes
HcalZeroSuppressionAlgo Class Referenceabstract

#include <HcalZeroSuppressionAlgo.h>

Inheritance diagram for HcalZeroSuppressionAlgo:
HcalZSAlgoEnergy HcalZSAlgoRealistic

Public Member Functions

void clearDbService ()
 
void setDbService (const HcalDbService *db)
 
virtual bool shouldKeep (const HBHEDataFrame &digi) const =0
 
virtual bool shouldKeep (const HODataFrame &digi) const =0
 
virtual bool shouldKeep (const HFDataFrame &digi) const =0
 
virtual bool shouldKeep (const QIE10DataFrame &digi) const =0
 
virtual bool shouldKeep (const QIE11DataFrame &digi) const =0
 
void suppress (const HBHEDigiCollection &input, HBHEDigiCollection &output)
 
void suppress (const HODigiCollection &input, HODigiCollection &output)
 
void suppress (const HFDigiCollection &input, HFDigiCollection &output)
 
void suppress (const QIE10DigiCollection &input, QIE10DigiCollection &output)
 
void suppress (const QIE11DigiCollection &input, QIE11DigiCollection &output)
 

Protected Member Functions

 HcalZeroSuppressionAlgo (bool markAndPass)
 

Protected Attributes

const HcalDbServicem_dbService
 

Private Attributes

bool m_markAndPass
 

Detailed Description

Definition at line 15 of file HcalZeroSuppressionAlgo.h.

Constructor & Destructor Documentation

HcalZeroSuppressionAlgo::HcalZeroSuppressionAlgo ( bool  markAndPass)
protected

Definition at line 3 of file HcalZeroSuppressionAlgo.cc.

References m_dbService.

Referenced by clearDbService().

3  : m_markAndPass(mp) {
4  m_dbService=0;
5 }
const HcalDbService * m_dbService

Member Function Documentation

void HcalZeroSuppressionAlgo::clearDbService ( )
inline
void HcalZeroSuppressionAlgo::setDbService ( const HcalDbService db)
inline

Definition at line 27 of file HcalZeroSuppressionAlgo.h.

References m_dbService.

27 { m_dbService=db; }
const HcalDbService * m_dbService
virtual bool HcalZeroSuppressionAlgo::shouldKeep ( const HBHEDataFrame digi) const
pure virtual

Implemented in HcalZSAlgoEnergy, and HcalZSAlgoRealistic.

Referenced by suppress().

virtual bool HcalZeroSuppressionAlgo::shouldKeep ( const HODataFrame digi) const
pure virtual

Implemented in HcalZSAlgoEnergy, and HcalZSAlgoRealistic.

virtual bool HcalZeroSuppressionAlgo::shouldKeep ( const HFDataFrame digi) const
pure virtual

Implemented in HcalZSAlgoEnergy, and HcalZSAlgoRealistic.

virtual bool HcalZeroSuppressionAlgo::shouldKeep ( const QIE10DataFrame digi) const
pure virtual

Implemented in HcalZSAlgoEnergy, and HcalZSAlgoRealistic.

virtual bool HcalZeroSuppressionAlgo::shouldKeep ( const QIE11DataFrame digi) const
pure virtual

Implemented in HcalZSAlgoEnergy, and HcalZSAlgoRealistic.

void HcalZeroSuppressionAlgo::suppress ( const HBHEDigiCollection input,
HBHEDigiCollection output 
)

Definition at line 8 of file HcalZeroSuppressionAlgo.cc.

References edm::SortedCollection< T, SORT >::begin(), edm::SortedCollection< T, SORT >::end(), mps_fire::i, m_markAndPass, edm::SortedCollection< T, SORT >::push_back(), HBHEDataFrame::setZSInfo(), and shouldKeep().

8  {
10 
11  for (i=input.begin(); i!=input.end(); ++i) {
12  if (shouldKeep((*i))) {
13  if (!m_markAndPass) {
14  output.push_back(*i);
15  } else {
16  HBHEDataFrame df(*i);
17  df.setZSInfo(true,false);
18  output.push_back(df);
19  }
20  } else if (m_markAndPass) {
21  HBHEDataFrame df(*i);
22  df.setZSInfo(true,true);
23  output.push_back(df);
24  }
25  }
26 }
std::vector< HBHEDataFrame >::const_iterator const_iterator
void push_back(T const &t)
const_iterator end() const
virtual bool shouldKeep(const HBHEDataFrame &digi) const =0
const_iterator begin() const
void HcalZeroSuppressionAlgo::suppress ( const HODigiCollection input,
HODigiCollection output 
)

Definition at line 48 of file HcalZeroSuppressionAlgo.cc.

References edm::SortedCollection< T, SORT >::begin(), edm::SortedCollection< T, SORT >::end(), mps_fire::i, m_markAndPass, edm::SortedCollection< T, SORT >::push_back(), HODataFrame::setZSInfo(), and shouldKeep().

48  {
50 
51  for (i=input.begin(); i!=input.end(); ++i) {
52  if (shouldKeep((*i))) {
53  if (!m_markAndPass) {
54  output.push_back(*i);
55  } else {
56  HODataFrame df(*i);
57  df.setZSInfo(true,false);
58  output.push_back(df);
59  }
60  } else if (m_markAndPass) {
61  HODataFrame df(*i);
62  df.setZSInfo(true,true);
63  output.push_back(df);
64  }
65  }
66 }
std::vector< HODataFrame >::const_iterator const_iterator
void push_back(T const &t)
const_iterator end() const
virtual bool shouldKeep(const HBHEDataFrame &digi) const =0
const_iterator begin() const
void HcalZeroSuppressionAlgo::suppress ( const HFDigiCollection input,
HFDigiCollection output 
)

Definition at line 28 of file HcalZeroSuppressionAlgo.cc.

References edm::SortedCollection< T, SORT >::begin(), edm::SortedCollection< T, SORT >::end(), mps_fire::i, m_markAndPass, edm::SortedCollection< T, SORT >::push_back(), HFDataFrame::setZSInfo(), and shouldKeep().

28  {
30 
31  for (i=input.begin(); i!=input.end(); ++i) {
32  if (shouldKeep((*i))) {
33  if (!m_markAndPass) {
34  output.push_back(*i);
35  } else {
36  HFDataFrame df(*i);
37  df.setZSInfo(true,false);
38  output.push_back(df);
39  }
40  } else if (m_markAndPass) {
41  HFDataFrame df(*i);
42  df.setZSInfo(true,true);
43  output.push_back(df);
44  }
45  }
46 }
std::vector< HFDataFrame >::const_iterator const_iterator
void push_back(T const &t)
const_iterator end() const
virtual bool shouldKeep(const HBHEDataFrame &digi) const =0
const_iterator begin() const
void HcalZeroSuppressionAlgo::suppress ( const QIE10DigiCollection input,
QIE10DigiCollection output 
)

Definition at line 68 of file HcalZeroSuppressionAlgo.cc.

References edm::DataFrameContainer::begin(), edm::DataFrameContainer::end(), mps_fire::i, m_markAndPass, HcalDataFrameContainer< Digi >::push_back(), QIE10DataFrame::setZSInfo(), and shouldKeep().

68  {
69  for (QIE10DigiCollection::const_iterator i=input.begin(); i!=input.end(); ++i) {
70  QIE10DataFrame df(*i);
71  if (shouldKeep(df)) {
72  if (!m_markAndPass) {
73  output.push_back(df);
74  } else {
75  df.setZSInfo(false);
76  output.push_back(df);
77  }
78  }
79  else if (m_markAndPass) {
80  df.setZSInfo(true);
81  output.push_back(df);
82  }
83  }
84 }
boost::transform_iterator< IterHelp, boost::counting_iterator< int > > const_iterator
const_iterator begin() const
const_iterator end() const
void push_back(const Digi &digi)
virtual bool shouldKeep(const HBHEDataFrame &digi) const =0
void HcalZeroSuppressionAlgo::suppress ( const QIE11DigiCollection input,
QIE11DigiCollection output 
)

Definition at line 86 of file HcalZeroSuppressionAlgo.cc.

References edm::DataFrameContainer::begin(), edm::DataFrameContainer::end(), mps_fire::i, m_markAndPass, HcalDataFrameContainer< Digi >::push_back(), QIE11DataFrame::setZSInfo(), and shouldKeep().

86  {
87  for (QIE11DigiCollection::const_iterator i=input.begin(); i!=input.end(); ++i) {
88  QIE11DataFrame df(*i);
89  if (shouldKeep(df)) {
90  if (!m_markAndPass) {
91  output.push_back(df);
92  } else {
93  df.setZSInfo(false);
94  output.push_back(df);
95  }
96  }
97  else if (m_markAndPass) {
98  df.setZSInfo(true);
99  output.push_back(df);
100  }
101  }
102 }
boost::transform_iterator< IterHelp, boost::counting_iterator< int > > const_iterator
const_iterator begin() const
const_iterator end() const
void push_back(const Digi &digi)
virtual bool shouldKeep(const HBHEDataFrame &digi) const =0

Member Data Documentation

const HcalDbService* HcalZeroSuppressionAlgo::m_dbService
protected
bool HcalZeroSuppressionAlgo::m_markAndPass
private

Definition at line 36 of file HcalZeroSuppressionAlgo.h.

Referenced by suppress().