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();
125 template <
class Archive>
133 namespace serialization {
134 template <
typename Item>
136 BOOST_STATIC_CONSTANT(
int,
value = 1);
141 #endif // CondFormats_HcalObjects_HcalItemCollById_h unsigned largestIndex() const
HcalItemColl< Item > coll_
bool isEqual(const AbsHcalAlgoData &other) const override
void serialize(Archive &ar, unsigned)
unsigned getIndex(const HcalDetId &id) const
const Item * getDefault() const
HcalItemCollById(const HcalItemColl< Item > &coll, const HcalIndexLookup &indexLookupTable, const unsigned detIdTransformCode, std::unique_ptr< Item > defaultItem)
const Item & at(const HcalDetId &id) const
std::shared_ptr< Item > default_
const Item * getByIndex(const unsigned index) const
unsigned find(unsigned detId) const
void setDefault(std::unique_ptr< Item > f)
friend class boost::serialization::access
static const unsigned InvalidIndex
~HcalItemCollById() override