Go to the documentation of this file. 1 #ifndef CondFormats_HcalObjects_HcalItemCollById_h
2 #define CondFormats_HcalObjects_HcalItemCollById_h
26 template <
typename Item>
37 const unsigned detIdTransformCode,
38 std::unique_ptr<Item> defaultItem)
43 "In HcalItemCollById constructor:"
44 " invalid lookup table");
51 "In HcalItemCollById constructor:"
52 " collection and lookup table are inconsistent");
63 inline std::size_t
size()
const {
return coll_.size(); }
93 throw cms::Exception(
"In HcalItemCollById::at: invalid detector id");
108 const bool rd =
r.default_.get();
123 friend class boost::serialization::access;
125 template <
class Archive>
133 namespace serialization {
134 template <
typename Item>
136 BOOST_STATIC_CONSTANT(
int,
value = 1);
141 #endif // CondFormats_HcalObjects_HcalItemCollById_h
bool isEqual(const AbsHcalAlgoData &other) const override
void serialize(Archive &ar, unsigned)
HcalItemColl< Item > coll_
const Item * getDefault() const
HcalItemCollById(const HcalItemColl< Item > &coll, const HcalIndexLookup &indexLookupTable, const unsigned detIdTransformCode, std::unique_ptr< Item > defaultItem)
unsigned getIndex(const HcalDetId &id) const
unsigned largestIndex() const
static const unsigned InvalidIndex
void setDefault(std::unique_ptr< Item > f)
const Item * getByIndex(const unsigned index) const
const Item * get(const HcalDetId &id) const
std::shared_ptr< Item > default_
const Item & at(const HcalDetId &id) const
unsigned find(unsigned detId) const
~HcalItemCollById() override