CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Types | Public Member Functions | Private Member Functions | Private Attributes | Friends
EcalCondTowerObjectContainer< T > Class Template Reference

#include <EcalCondTowerObjectContainer.h>

Public Types

typedef std::vector< Item >
::const_iterator 
const_iterator
 
typedef T Item
 
typedef std::vector< ItemItems
 
typedef std::vector< Item >
::iterator 
iterator
 
typedef
EcalCondTowerObjectContainer
< T
self
 
typedef Item value_type
 

Public Member Functions

const Itembarrel (size_t hashedIndex) const
 
const ItemsbarrelItems () const
 
const_iterator begin () const
 
 EcalCondTowerObjectContainer ()
 
const_iterator end () const
 
const Itemendcap (size_t hashedIndex) const
 
const ItemsendcapItems () const
 
const_iterator find (uint32_t rawId) const
 
const selfgetMap () const
 
void insert (std::pair< uint32_t, Item > const &a)
 
Itemoperator[] (uint32_t rawId)
 
Item operator[] (uint32_t rawId) const
 
void setValue (const uint32_t id, const Item &item)
 
size_t size () const
 
 ~EcalCondTowerObjectContainer ()
 

Private Member Functions

template<class Archive >
void serialize (Archive &ar, const unsigned int version)
 

Private Attributes

EcalContainer
< EcalTrigTowerDetId, Item
eb_
 
EcalContainer< EcalScDetId, Itemee_
 

Friends

class boost::serialization::access
 
template<typename CondSerializationT , typename Enabled >
struct cond::serialization::access
 

Detailed Description

template<typename T>
class EcalCondTowerObjectContainer< T >

Definition at line 13 of file EcalCondTowerObjectContainer.h.

Member Typedef Documentation

template<typename T >
typedef std::vector<Item>::const_iterator EcalCondTowerObjectContainer< T >::const_iterator

Definition at line 19 of file EcalCondTowerObjectContainer.h.

template<typename T >
typedef T EcalCondTowerObjectContainer< T >::Item

Definition at line 15 of file EcalCondTowerObjectContainer.h.

template<typename T >
typedef std::vector<Item> EcalCondTowerObjectContainer< T >::Items

Definition at line 18 of file EcalCondTowerObjectContainer.h.

template<typename T >
typedef std::vector<Item>::iterator EcalCondTowerObjectContainer< T >::iterator

Definition at line 20 of file EcalCondTowerObjectContainer.h.

Definition at line 17 of file EcalCondTowerObjectContainer.h.

template<typename T >
typedef Item EcalCondTowerObjectContainer< T >::value_type

Definition at line 16 of file EcalCondTowerObjectContainer.h.

Constructor & Destructor Documentation

template<typename T >
EcalCondTowerObjectContainer< T >::EcalCondTowerObjectContainer ( )
inline

Definition at line 22 of file EcalCondTowerObjectContainer.h.

References EcalContainer< DetId, T >::checkAndResize(), EcalCondTowerObjectContainer< T >::eb_, EcalCondTowerObjectContainer< T >::ee_, and EcalTrigTowerDetId::kEBTowersPerSM.

22  {
23  size_t ebsize = (size_t)EcalTrigTowerDetId::kEBTowersPerSM * 18 * 2;
24  eb_.checkAndResize(ebsize);
25  size_t eesize = (size_t)632;
26  ee_.checkAndResize(eesize);
27  };
EcalContainer< EcalScDetId, Item > ee_
void checkAndResize()
Definition: EcalContainer.h:47
EcalContainer< EcalTrigTowerDetId, Item > eb_
static const int kEBTowersPerSM
template<typename T >
EcalCondTowerObjectContainer< T >::~EcalCondTowerObjectContainer ( )
inline

Definition at line 28 of file EcalCondTowerObjectContainer.h.

28 {};

Member Function Documentation

template<typename T >
const Item& EcalCondTowerObjectContainer< T >::barrel ( size_t  hashedIndex) const
inline

Definition at line 34 of file EcalCondTowerObjectContainer.h.

References EcalCondTowerObjectContainer< T >::eb_, and EcalContainer< DetId, T >::item().

Referenced by ecaldqm::TowerStatusTask::endLuminosityBlock(), and popcon::EcalDAQHandler::getNewObjects().

34 { return eb_.item(hashedIndex); }
const Item & item(size_t hashid) const
Definition: EcalContainer.h:34
int hashedIndex(int ieta, int iphi)
Definition: EcalPyUtils.cc:36
EcalContainer< EcalTrigTowerDetId, Item > eb_
template<typename T >
const Items& EcalCondTowerObjectContainer< T >::barrelItems ( ) const
inline
template<typename T >
const_iterator EcalCondTowerObjectContainer< T >::begin ( void  ) const
inline

Definition at line 65 of file EcalCondTowerObjectContainer.h.

References EcalContainer< DetId, T >::begin(), and EcalCondTowerObjectContainer< T >::eb_.

65 { return eb_.begin(); }
const_iterator begin() const
Definition: EcalContainer.h:80
EcalContainer< EcalTrigTowerDetId, Item > eb_
template<typename T >
const_iterator EcalCondTowerObjectContainer< T >::end ( void  ) const
inline
template<typename T >
const Item& EcalCondTowerObjectContainer< T >::endcap ( size_t  hashedIndex) const
inline

Definition at line 36 of file EcalCondTowerObjectContainer.h.

References EcalCondTowerObjectContainer< T >::ee_, and EcalContainer< DetId, T >::item().

Referenced by ecaldqm::TowerStatusTask::endLuminosityBlock(), and geometryXMLparser.CSCAlignable::index().

36 { return ee_.item(hashedIndex); }
const Item & item(size_t hashid) const
Definition: EcalContainer.h:34
int hashedIndex(int ieta, int iphi)
Definition: EcalPyUtils.cc:36
EcalContainer< EcalScDetId, Item > ee_
template<typename T >
const Items& EcalCondTowerObjectContainer< T >::endcapItems ( ) const
inline
template<typename T >
const_iterator EcalCondTowerObjectContainer< T >::find ( uint32_t  rawId) const
inline

Definition at line 49 of file EcalCondTowerObjectContainer.h.

References EcalCondTowerObjectContainer< T >::eb_, EcalBarrel, EcalEndcap, EcalTriggerTower, EcalCondTowerObjectContainer< T >::ee_, EcalContainer< DetId, T >::end(), EcalContainer< DetId, T >::find(), and gpuClustering::id.

Referenced by BeautifulSoup.Tag::__getattr__(), EcalDAQTowerStatusXMLTranslator::dumpXML(), EcalDCSTowerStatusXMLTranslator::dumpXML(), BeautifulSoup.Tag::firstText(), popcon::EcalDAQHandler::getNewObjects(), popcon::EcalDCSHandler::insertHVDataSetToOffline(), popcon::EcalDCSHandler::insertLVDataSetToOffline(), EcalDAQTowerStatusXMLTranslator::plot(), and EcalDCSTowerStatusXMLTranslator::plot().

49  {
50  DetId id(rawId);
51  if (id.subdetId() == EcalBarrel || id.subdetId() == EcalTriggerTower) {
52  const_iterator it = eb_.find(rawId);
53  if (it != eb_.end()) {
54  return it;
55  } else {
56  return ee_.end();
57  }
58  } else if (id.subdetId() == EcalEndcap) {
59  return ee_.find(rawId);
60  } else {
61  return ee_.end();
62  }
63  }
uint16_t *__restrict__ id
const_iterator end() const
Definition: EcalContainer.h:82
const_iterator find(uint32_t rawId) const
Definition: EcalContainer.h:73
EcalContainer< EcalScDetId, Item > ee_
Definition: DetId.h:17
EcalContainer< EcalTrigTowerDetId, Item > eb_
std::vector< Item >::const_iterator const_iterator
template<typename T >
const self& EcalCondTowerObjectContainer< T >::getMap ( ) const
inline

Definition at line 71 of file EcalCondTowerObjectContainer.h.

71 { return *this; }
template<typename T >
void EcalCondTowerObjectContainer< T >::insert ( std::pair< uint32_t, Item > const &  a)
inline

Definition at line 38 of file EcalCondTowerObjectContainer.h.

References EcalCondTowerObjectContainer< T >::eb_, EcalBarrel, EcalEndcap, EcalTriggerTower, EcalCondTowerObjectContainer< T >::ee_, gpuClustering::id, and EcalContainer< DetId, T >::insert().

Referenced by BeautifulSoup.PageElement::_invert(), and SequenceTypes.Schedule::_replaceIfHeldDirectly().

38  {
39  DetId id(a.first);
40  if (id.subdetId() == EcalBarrel || id.subdetId() == EcalTriggerTower) {
41  eb_.insert(a);
42  } else if (id.subdetId() == EcalEndcap) {
43  ee_.insert(a);
44  } else {
45  // std::cout <<"*** ERROR it is not barrel nor endcap tower"<< std::endl;
46  }
47  }
uint16_t *__restrict__ id
EcalContainer< EcalScDetId, Item > ee_
Definition: DetId.h:17
void insert(std::pair< uint32_t, Item > const &a)
Definition: EcalContainer.h:32
double a
Definition: hdecay.h:119
EcalContainer< EcalTrigTowerDetId, Item > eb_
template<typename T >
Item& EcalCondTowerObjectContainer< T >::operator[] ( uint32_t  rawId)
inline

Definition at line 76 of file EcalCondTowerObjectContainer.h.

References EcalCondTowerObjectContainer< T >::eb_, EcalBarrel, EcalTriggerTower, EcalCondTowerObjectContainer< T >::ee_, and gpuClustering::id.

76  {
77  DetId id(rawId);
78  return ((id.subdetId() == EcalBarrel) | (id.subdetId() == EcalTriggerTower)) ? eb_[rawId] : ee_[rawId];
79  }
uint16_t *__restrict__ id
EcalContainer< EcalScDetId, Item > ee_
Definition: DetId.h:17
EcalContainer< EcalTrigTowerDetId, Item > eb_
template<typename T >
Item EcalCondTowerObjectContainer< T >::operator[] ( uint32_t  rawId) const
inline

Definition at line 81 of file EcalCondTowerObjectContainer.h.

References EcalCondTowerObjectContainer< T >::eb_, EcalBarrel, EcalEndcap, EcalTriggerTower, EcalCondTowerObjectContainer< T >::ee_, and gpuClustering::id.

81  {
82  DetId id(rawId);
83 
84  if (id.subdetId() == EcalBarrel || id.subdetId() == EcalTriggerTower) {
85  return eb_[rawId];
86  } else if (id.subdetId() == EcalEndcap) {
87  return ee_[rawId];
88  } else {
89  return Item();
90  }
91  }
uint16_t *__restrict__ id
EcalContainer< EcalScDetId, Item > ee_
Definition: DetId.h:17
EcalContainer< EcalTrigTowerDetId, Item > eb_
template<typename T >
template<class Archive >
void EcalCondTowerObjectContainer< T >::serialize ( Archive &  ar,
const unsigned int  version 
)
private
template<typename T >
void EcalCondTowerObjectContainer< T >::setValue ( const uint32_t  id,
const Item item 
)
inline
template<typename T >
size_t EcalCondTowerObjectContainer< T >::size ( void  ) const
inline

Friends And Related Function Documentation

template<typename T >
friend class boost::serialization::access
friend

Definition at line 97 of file EcalCondTowerObjectContainer.h.

template<typename T >
template<typename CondSerializationT , typename Enabled >
friend struct cond::serialization::access
friend

Definition at line 97 of file EcalCondTowerObjectContainer.h.

Member Data Documentation

template<typename T >
EcalContainer<EcalTrigTowerDetId, Item> EcalCondTowerObjectContainer< T >::eb_
private
template<typename T >
EcalContainer<EcalScDetId, Item> EcalCondTowerObjectContainer< T >::ee_
private