Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2022-08-26 00:19:00

0001 #ifndef HLTReco_TriggerEventWithRefs_h
0002 #define HLTReco_TriggerEventWithRefs_h
0003 
0004 /** \class trigger::TriggerEventWithRefs
0005  *
0006  *  The single EDProduct to be saved for events (RAW case)
0007  *  describing the details of the (HLT) trigger table
0008  *
0009  *
0010  *  \author Martin Grunewald
0011  *
0012  */
0013 
0014 #include "DataFormats/HLTReco/interface/TriggerTypeDefs.h"
0015 #include "DataFormats/HLTReco/interface/TriggerRefsCollections.h"
0016 #include "DataFormats/HLTReco/interface/TriggerFilterObjectWithRefs.h"
0017 #include "FWCore/Utilities/interface/InputTag.h"
0018 #include "DataFormats/Common/interface/traits.h"
0019 #include <string>
0020 #include <vector>
0021 
0022 namespace trigger {
0023 
0024   /// The single EDProduct to be saved in addition for each event
0025   /// - but only in the "RAW" case: for a fraction of all events
0026 
0027   class TriggerEventWithRefs : public TriggerRefsCollections, public edm::DoNotRecordParents {
0028   public:
0029     /// Helper class: trigger objects firing a single filter
0030     class TriggerFilterObject {
0031     public:
0032       /// encoded InputTag of filter product
0033       std::string filterTag_;
0034       /// 1-after-end (std C++) indices into linearised vector of Refs
0035       /// (-> first start index is always 0)
0036       size_type photons_;
0037       size_type electrons_;
0038       size_type muons_;
0039       size_type jets_;
0040       size_type composites_;
0041       size_type basemets_;
0042       size_type calomets_;
0043       size_type pixtracks_;
0044       size_type l1em_;
0045       size_type l1muon_;
0046       size_type l1jet_;
0047       size_type l1etmiss_;
0048       size_type l1hfrings_;
0049       size_type pfjets_;
0050       size_type pftaus_;
0051       size_type pfmets_;
0052       size_type l1tmuon_;
0053       size_type l1tmuonShower_;
0054       size_type l1tegamma_;
0055       size_type l1tjet_;
0056       size_type l1ttkmuon_;
0057       size_type l1ttkele_;
0058       size_type l1ttkem_;
0059       size_type l1tpfjet_;
0060       size_type l1tpftau_;
0061       size_type l1thpspftau_;
0062       size_type l1tpftrack_;
0063       size_type l1tp2etsum_;
0064       size_type l1ttau_;
0065       size_type l1tetsum_;
0066 
0067       /// constructor
0068       TriggerFilterObject()
0069           : filterTag_(),
0070             photons_(0),
0071             electrons_(0),
0072             muons_(0),
0073             jets_(0),
0074             composites_(0),
0075             basemets_(0),
0076             calomets_(0),
0077             pixtracks_(0),
0078             l1em_(0),
0079             l1muon_(0),
0080             l1jet_(0),
0081             l1etmiss_(0),
0082             l1hfrings_(0),
0083             pfjets_(0),
0084             pftaus_(0),
0085             pfmets_(0),
0086             l1tmuon_(0),
0087             l1tmuonShower_(0),
0088             l1tegamma_(0),
0089             l1tjet_(0),
0090             l1ttkmuon_(0),
0091             l1ttkele_(0),
0092             l1ttkem_(0),
0093             l1tpfjet_(0),
0094             l1tpftau_(0),
0095             l1thpspftau_(0),
0096             l1tpftrack_(0),
0097             l1tp2etsum_(0),
0098             l1ttau_(0),
0099             l1tetsum_(0) {
0100         filterTag_ = edm::InputTag().encode();
0101       }
0102       TriggerFilterObject(const edm::InputTag& filterTag,
0103                           size_type np,
0104                           size_type ne,
0105                           size_type nm,
0106                           size_type nj,
0107                           size_type nc,
0108                           size_type nB,
0109                           size_type nC,
0110                           size_type nt,
0111                           size_type l1em,
0112                           size_type l1muon,
0113                           size_type l1jet,
0114                           size_type l1etmiss,
0115                           size_type l1hfrings,
0116                           size_type pfjets,
0117                           size_type pftaus,
0118                           size_type pfmets,
0119                           size_type l1tmuon,
0120                           size_type l1tmuonShower,
0121                           size_type l1tegamma,
0122                           size_type l1tjet,
0123                           size_type l1ttkmuon,
0124                           size_type l1ttkele,
0125                           size_type l1ttkem,
0126                           size_type l1tpfjet,
0127                           size_type l1tpftau,
0128                           size_type l1thpspftau,
0129                           size_type l1tpftrack,
0130                           size_type l1tp2etsum,
0131                           size_type l1ttau,
0132                           size_type l1tetsum)
0133           : filterTag_(filterTag.encode()),
0134             photons_(np),
0135             electrons_(ne),
0136             muons_(nm),
0137             jets_(nj),
0138             composites_(nc),
0139             basemets_(nB),
0140             calomets_(nC),
0141             pixtracks_(nt),
0142             l1em_(l1em),
0143             l1muon_(l1muon),
0144             l1jet_(l1jet),
0145             l1etmiss_(l1etmiss),
0146             l1hfrings_(l1hfrings),
0147             pfjets_(pfjets),
0148             pftaus_(pftaus),
0149             pfmets_(pfmets),
0150             l1tmuon_(l1tmuon),
0151             l1tmuonShower_(l1tmuonShower),
0152             l1tegamma_(l1tegamma),
0153             l1tjet_(l1tjet),
0154             l1ttkmuon_(l1ttkmuon),
0155             l1ttkele_(l1ttkele),
0156             l1ttkem_(l1ttkem),
0157             l1tpfjet_(l1tpfjet),
0158             l1tpftau_(l1tpftau),
0159             l1thpspftau_(l1thpspftau),
0160             l1tpftrack_(l1tpftrack),
0161             l1tp2etsum_(l1tp2etsum),
0162             l1ttau_(l1ttau),
0163             l1tetsum_(l1tetsum) {}
0164     };
0165 
0166     /// data members
0167   private:
0168     /// processName used to select products packed up
0169     std::string usedProcessName_;
0170     /// the filters recorded here
0171     std::vector<TriggerFilterObject> filterObjects_;
0172 
0173     /// methods
0174   public:
0175     /// constructors
0176     TriggerEventWithRefs() : TriggerRefsCollections(), usedProcessName_(), filterObjects_() {}
0177     TriggerEventWithRefs(const std::string& usedProcessName, size_type n)
0178         : TriggerRefsCollections(), usedProcessName_(usedProcessName), filterObjects_() {
0179       filterObjects_.reserve(n);
0180     }
0181 
0182     /// setters - to build EDProduct
0183     void addFilterObject(const edm::InputTag& filterTag, const TriggerFilterObjectWithRefs& tfowr) {
0184       filterObjects_.push_back(
0185 
0186           TriggerFilterObject(filterTag,
0187                               addObjects(tfowr.photonIds(), tfowr.photonRefs()),
0188                               addObjects(tfowr.electronIds(), tfowr.electronRefs()),
0189                               addObjects(tfowr.muonIds(), tfowr.muonRefs()),
0190                               addObjects(tfowr.jetIds(), tfowr.jetRefs()),
0191                               addObjects(tfowr.compositeIds(), tfowr.compositeRefs()),
0192                               addObjects(tfowr.basemetIds(), tfowr.basemetRefs()),
0193                               addObjects(tfowr.calometIds(), tfowr.calometRefs()),
0194                               addObjects(tfowr.pixtrackIds(), tfowr.pixtrackRefs()),
0195                               addObjects(tfowr.l1emIds(), tfowr.l1emRefs()),
0196                               addObjects(tfowr.l1muonIds(), tfowr.l1muonRefs()),
0197                               addObjects(tfowr.l1jetIds(), tfowr.l1jetRefs()),
0198                               addObjects(tfowr.l1etmissIds(), tfowr.l1etmissRefs()),
0199                               addObjects(tfowr.l1hfringsIds(), tfowr.l1hfringsRefs()),
0200                               addObjects(tfowr.pfjetIds(), tfowr.pfjetRefs()),
0201                               addObjects(tfowr.pftauIds(), tfowr.pftauRefs()),
0202                               addObjects(tfowr.pfmetIds(), tfowr.pfmetRefs()),
0203                               addObjects(tfowr.l1tmuonIds(), tfowr.l1tmuonRefs()),
0204                               addObjects(tfowr.l1tmuonShowerIds(), tfowr.l1tmuonShowerRefs()),
0205                               addObjects(tfowr.l1tegammaIds(), tfowr.l1tegammaRefs()),
0206                               addObjects(tfowr.l1tjetIds(), tfowr.l1tjetRefs()),
0207                               addObjects(tfowr.l1ttkmuonIds(), tfowr.l1ttkmuonRefs()),
0208                               addObjects(tfowr.l1ttkeleIds(), tfowr.l1ttkeleRefs()),
0209                               addObjects(tfowr.l1ttkemIds(), tfowr.l1ttkemRefs()),
0210                               addObjects(tfowr.l1tpfjetIds(), tfowr.l1tpfjetRefs()),
0211                               addObjects(tfowr.l1tpftauIds(), tfowr.l1tpftauRefs()),
0212                               addObjects(tfowr.l1thpspftauIds(), tfowr.l1thpspftauRefs()),
0213                               addObjects(tfowr.l1tpftrackIds(), tfowr.l1tpftrackRefs()),
0214                               addObjects(tfowr.l1tp2etsumIds(), tfowr.l1tp2etsumRefs()),
0215                               addObjects(tfowr.l1ttauIds(), tfowr.l1ttauRefs()),
0216                               addObjects(tfowr.l1tetsumIds(), tfowr.l1tetsumRefs()))
0217 
0218       );
0219     }
0220 
0221     /// getters - for user access
0222     const std::string& usedProcessName() const { return usedProcessName_; }
0223 
0224     /// number of filters
0225     size_type size() const { return filterObjects_.size(); }
0226 
0227     /// tag from index
0228     const edm::InputTag filterTag(size_type filterIndex) const {
0229       return edm::InputTag(filterObjects_.at(filterIndex).filterTag_);
0230     }
0231 
0232     /// index from tag
0233     size_type filterIndex(const edm::InputTag& filterTag) const {
0234       const std::string encodedFilterTag(filterTag.encode());
0235       const size_type n(filterObjects_.size());
0236       for (size_type i = 0; i != n; ++i) {
0237         if (encodedFilterTag == filterObjects_[i].filterTag_) {
0238           return i;
0239         }
0240       }
0241       return n;
0242     }
0243 
0244     /// slices of objects for a specific filter: [begin,end[
0245 
0246     std::pair<size_type, size_type> photonSlice(size_type filter) const {
0247       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).photons_);
0248       const size_type end(filterObjects_.at(filter).photons_);
0249       return std::pair<size_type, size_type>(begin, end);
0250     }
0251 
0252     std::pair<size_type, size_type> electronSlice(size_type filter) const {
0253       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).electrons_);
0254       const size_type end(filterObjects_.at(filter).electrons_);
0255       return std::pair<size_type, size_type>(begin, end);
0256     }
0257 
0258     std::pair<size_type, size_type> muonSlice(size_type filter) const {
0259       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).muons_);
0260       const size_type end(filterObjects_.at(filter).muons_);
0261       return std::pair<size_type, size_type>(begin, end);
0262     }
0263 
0264     std::pair<size_type, size_type> jetSlice(size_type filter) const {
0265       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).jets_);
0266       const size_type end(filterObjects_.at(filter).jets_);
0267       return std::pair<size_type, size_type>(begin, end);
0268     }
0269 
0270     std::pair<size_type, size_type> compositeSlice(size_type filter) const {
0271       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).composites_);
0272       const size_type end(filterObjects_.at(filter).composites_);
0273       return std::pair<size_type, size_type>(begin, end);
0274     }
0275 
0276     std::pair<size_type, size_type> basemetSlice(size_type filter) const {
0277       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).basemets_);
0278       const size_type end(filterObjects_.at(filter).basemets_);
0279       return std::pair<size_type, size_type>(begin, end);
0280     }
0281 
0282     std::pair<size_type, size_type> calometSlice(size_type filter) const {
0283       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).calomets_);
0284       const size_type end(filterObjects_.at(filter).calomets_);
0285       return std::pair<size_type, size_type>(begin, end);
0286     }
0287 
0288     std::pair<size_type, size_type> pixtrackSlice(size_type filter) const {
0289       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).pixtracks_);
0290       const size_type end(filterObjects_.at(filter).pixtracks_);
0291       return std::pair<size_type, size_type>(begin, end);
0292     }
0293 
0294     std::pair<size_type, size_type> l1emSlice(size_type filter) const {
0295       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1em_);
0296       const size_type end(filterObjects_.at(filter).l1em_);
0297       return std::pair<size_type, size_type>(begin, end);
0298     }
0299 
0300     std::pair<size_type, size_type> l1muonSlice(size_type filter) const {
0301       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1muon_);
0302       const size_type end(filterObjects_.at(filter).l1muon_);
0303       return std::pair<size_type, size_type>(begin, end);
0304     }
0305 
0306     std::pair<size_type, size_type> l1jetSlice(size_type filter) const {
0307       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1jet_);
0308       const size_type end(filterObjects_.at(filter).l1jet_);
0309       return std::pair<size_type, size_type>(begin, end);
0310     }
0311 
0312     std::pair<size_type, size_type> l1etmissSlice(size_type filter) const {
0313       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1etmiss_);
0314       const size_type end(filterObjects_.at(filter).l1etmiss_);
0315       return std::pair<size_type, size_type>(begin, end);
0316     }
0317 
0318     std::pair<size_type, size_type> l1hfringsSlice(size_type filter) const {
0319       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1hfrings_);
0320       const size_type end(filterObjects_.at(filter).l1hfrings_);
0321       return std::pair<size_type, size_type>(begin, end);
0322     }
0323 
0324     std::pair<size_type, size_type> pfjetSlice(size_type filter) const {
0325       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).pfjets_);
0326       const size_type end(filterObjects_.at(filter).pfjets_);
0327       return std::pair<size_type, size_type>(begin, end);
0328     }
0329 
0330     std::pair<size_type, size_type> pftauSlice(size_type filter) const {
0331       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).pftaus_);
0332       const size_type end(filterObjects_.at(filter).pftaus_);
0333       return std::pair<size_type, size_type>(begin, end);
0334     }
0335 
0336     std::pair<size_type, size_type> pfmetSlice(size_type filter) const {
0337       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).pfmets_);
0338       const size_type end(filterObjects_.at(filter).pfmets_);
0339       return std::pair<size_type, size_type>(begin, end);
0340     }
0341 
0342     std::pair<size_type, size_type> l1tmuonSlice(size_type filter) const {
0343       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1tmuon_);
0344       const size_type end(filterObjects_.at(filter).l1tmuon_);
0345       return std::pair<size_type, size_type>(begin, end);
0346     }
0347     std::pair<size_type, size_type> l1tmuonShowerSlice(size_type filter) const {
0348       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1tmuonShower_);
0349       const size_type end(filterObjects_.at(filter).l1tmuonShower_);
0350       return std::pair<size_type, size_type>(begin, end);
0351     }
0352     std::pair<size_type, size_type> l1tegammaSlice(size_type filter) const {
0353       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1tegamma_);
0354       const size_type end(filterObjects_.at(filter).l1tegamma_);
0355       return std::pair<size_type, size_type>(begin, end);
0356     }
0357     std::pair<size_type, size_type> l1tjetSlice(size_type filter) const {
0358       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1tjet_);
0359       const size_type end(filterObjects_.at(filter).l1tjet_);
0360       return std::pair<size_type, size_type>(begin, end);
0361     }
0362 
0363     /* Phase-2 */
0364     std::pair<size_type, size_type> l1ttkmuonSlice(size_type filter) const {
0365       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1ttkmuon_);
0366       const size_type end(filterObjects_.at(filter).l1ttkmuon_);
0367       return std::pair<size_type, size_type>(begin, end);
0368     }
0369     std::pair<size_type, size_type> l1ttkeleSlice(size_type filter) const {
0370       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1ttkele_);
0371       const size_type end(filterObjects_.at(filter).l1ttkele_);
0372       return std::pair<size_type, size_type>(begin, end);
0373     }
0374     std::pair<size_type, size_type> l1ttkemSlice(size_type filter) const {
0375       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1ttkem_);
0376       const size_type end(filterObjects_.at(filter).l1ttkem_);
0377       return std::pair<size_type, size_type>(begin, end);
0378     }
0379     std::pair<size_type, size_type> l1tpfjetSlice(size_type filter) const {
0380       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1tpfjet_);
0381       const size_type end(filterObjects_.at(filter).l1tpfjet_);
0382       return std::pair<size_type, size_type>(begin, end);
0383     }
0384     std::pair<size_type, size_type> l1tpftauSlice(size_type filter) const {
0385       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1tpftau_);
0386       const size_type end(filterObjects_.at(filter).l1tpftau_);
0387       return std::pair<size_type, size_type>(begin, end);
0388     }
0389     std::pair<size_type, size_type> l1thpspftauSlice(size_type filter) const {
0390       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1thpspftau_);
0391       const size_type end(filterObjects_.at(filter).l1thpspftau_);
0392       return std::pair<size_type, size_type>(begin, end);
0393     }
0394     std::pair<size_type, size_type> l1tpftrackSlice(size_type filter) const {
0395       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1tpftrack_);
0396       const size_type end(filterObjects_.at(filter).l1tpftrack_);
0397       return std::pair<size_type, size_type>(begin, end);
0398     }
0399 
0400     std::pair<size_type, size_type> l1tp2etsumSlice(size_type filter) const {
0401       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1tp2etsum_);
0402       const size_type end(filterObjects_.at(filter).l1tp2etsum_);
0403       return std::pair<size_type, size_type>(begin, end);
0404     }
0405 
0406     std::pair<size_type, size_type> l1ttauSlice(size_type filter) const {
0407       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1ttau_);
0408       const size_type end(filterObjects_.at(filter).l1ttau_);
0409       return std::pair<size_type, size_type>(begin, end);
0410     }
0411 
0412     std::pair<size_type, size_type> l1tetsumSlice(size_type filter) const {
0413       const size_type begin(filter == 0 ? 0 : filterObjects_.at(filter - 1).l1tetsum_);
0414       const size_type end(filterObjects_.at(filter).l1tetsum_);
0415       return std::pair<size_type, size_type>(begin, end);
0416     }
0417 
0418     /// extract Ref<C>s for a specific filter and of specific physics type
0419 
0420     void getObjects(size_type filter, Vids& ids, VRphoton& photons) const {
0421       const size_type begin(photonSlice(filter).first);
0422       const size_type end(photonSlice(filter).second);
0423       TriggerRefsCollections::getObjects(ids, photons, begin, end);
0424     }
0425     void getObjects(size_type filter, int id, VRphoton& photons) const {
0426       const size_type begin(photonSlice(filter).first);
0427       const size_type end(photonSlice(filter).second);
0428       TriggerRefsCollections::getObjects(id, photons, begin, end);
0429     }
0430 
0431     void getObjects(size_type filter, Vids& ids, VRelectron& electrons) const {
0432       const size_type begin(electronSlice(filter).first);
0433       const size_type end(electronSlice(filter).second);
0434       TriggerRefsCollections::getObjects(ids, electrons, begin, end);
0435     }
0436     void getObjects(size_type filter, int id, VRelectron& electrons) const {
0437       const size_type begin(electronSlice(filter).first);
0438       const size_type end(electronSlice(filter).second);
0439       TriggerRefsCollections::getObjects(id, electrons, begin, end);
0440     }
0441 
0442     void getObjects(size_type filter, Vids& ids, VRmuon& muons) const {
0443       const size_type begin(muonSlice(filter).first);
0444       const size_type end(muonSlice(filter).second);
0445       TriggerRefsCollections::getObjects(ids, muons, begin, end);
0446     }
0447     void getObjects(size_type filter, int id, VRmuon& muons) const {
0448       const size_type begin(muonSlice(filter).first);
0449       const size_type end(muonSlice(filter).second);
0450       TriggerRefsCollections::getObjects(id, muons, begin, end);
0451     }
0452 
0453     void getObjects(size_type filter, Vids& ids, VRjet& jets) const {
0454       const size_type begin(jetSlice(filter).first);
0455       const size_type end(jetSlice(filter).second);
0456       TriggerRefsCollections::getObjects(ids, jets, begin, end);
0457     }
0458     void getObjects(size_type filter, int id, VRjet& jets) const {
0459       const size_type begin(jetSlice(filter).first);
0460       const size_type end(jetSlice(filter).second);
0461       TriggerRefsCollections::getObjects(id, jets, begin, end);
0462     }
0463 
0464     void getObjects(size_type filter, Vids& ids, VRcomposite& composites) const {
0465       const size_type begin(compositeSlice(filter).first);
0466       const size_type end(compositeSlice(filter).second);
0467       TriggerRefsCollections::getObjects(ids, composites, begin, end);
0468     }
0469     void getObjects(size_type filter, int id, VRcomposite& composites) const {
0470       const size_type begin(compositeSlice(filter).first);
0471       const size_type end(compositeSlice(filter).second);
0472       TriggerRefsCollections::getObjects(id, composites, begin, end);
0473     }
0474 
0475     void getObjects(size_type filter, Vids& ids, VRbasemet& basemets) const {
0476       const size_type begin(basemetSlice(filter).first);
0477       const size_type end(basemetSlice(filter).second);
0478       TriggerRefsCollections::getObjects(ids, basemets, begin, end);
0479     }
0480     void getObjects(size_type filter, int id, VRbasemet& basemets) const {
0481       const size_type begin(basemetSlice(filter).first);
0482       const size_type end(basemetSlice(filter).second);
0483       TriggerRefsCollections::getObjects(id, basemets, begin, end);
0484     }
0485 
0486     void getObjects(size_type filter, Vids& ids, VRcalomet& calomets) const {
0487       const size_type begin(calometSlice(filter).first);
0488       const size_type end(calometSlice(filter).second);
0489       TriggerRefsCollections::getObjects(ids, calomets, begin, end);
0490     }
0491     void getObjects(size_type filter, int id, VRcalomet& calomets) const {
0492       const size_type begin(calometSlice(filter).first);
0493       const size_type end(calometSlice(filter).second);
0494       TriggerRefsCollections::getObjects(id, calomets, begin, end);
0495     }
0496 
0497     void getObjects(size_type filter, Vids& ids, VRpixtrack& pixtracks) const {
0498       const size_type begin(pixtrackSlice(filter).first);
0499       const size_type end(pixtrackSlice(filter).second);
0500       TriggerRefsCollections::getObjects(ids, pixtracks, begin, end);
0501     }
0502     void getObjects(size_type filter, int id, VRpixtrack& pixtracks) const {
0503       const size_type begin(pixtrackSlice(filter).first);
0504       const size_type end(pixtrackSlice(filter).second);
0505       TriggerRefsCollections::getObjects(id, pixtracks, begin, end);
0506     }
0507 
0508     void getObjects(size_type filter, Vids& ids, VRl1em& l1em) const {
0509       const size_type begin(l1emSlice(filter).first);
0510       const size_type end(l1emSlice(filter).second);
0511       TriggerRefsCollections::getObjects(ids, l1em, begin, end);
0512     }
0513     void getObjects(size_type filter, int id, VRl1em& l1em) const {
0514       const size_type begin(l1emSlice(filter).first);
0515       const size_type end(l1emSlice(filter).second);
0516       TriggerRefsCollections::getObjects(id, l1em, begin, end);
0517     }
0518 
0519     void getObjects(size_type filter, Vids& ids, VRl1muon& l1muon) const {
0520       const size_type begin(l1muonSlice(filter).first);
0521       const size_type end(l1muonSlice(filter).second);
0522       TriggerRefsCollections::getObjects(ids, l1muon, begin, end);
0523     }
0524     void getObjects(size_type filter, int id, VRl1muon& l1muon) const {
0525       const size_type begin(l1muonSlice(filter).first);
0526       const size_type end(l1muonSlice(filter).second);
0527       TriggerRefsCollections::getObjects(id, l1muon, begin, end);
0528     }
0529 
0530     void getObjects(size_type filter, Vids& ids, VRl1jet& l1jet) const {
0531       const size_type begin(l1jetSlice(filter).first);
0532       const size_type end(l1jetSlice(filter).second);
0533       TriggerRefsCollections::getObjects(ids, l1jet, begin, end);
0534     }
0535     void getObjects(size_type filter, int id, VRl1jet& l1jet) const {
0536       const size_type begin(l1jetSlice(filter).first);
0537       const size_type end(l1jetSlice(filter).second);
0538       TriggerRefsCollections::getObjects(id, l1jet, begin, end);
0539     }
0540 
0541     void getObjects(size_type filter, Vids& ids, VRl1etmiss& l1etmiss) const {
0542       const size_type begin(l1etmissSlice(filter).first);
0543       const size_type end(l1etmissSlice(filter).second);
0544       TriggerRefsCollections::getObjects(ids, l1etmiss, begin, end);
0545     }
0546     void getObjects(size_type filter, int id, VRl1etmiss& l1etmiss) const {
0547       const size_type begin(l1etmissSlice(filter).first);
0548       const size_type end(l1etmissSlice(filter).second);
0549       TriggerRefsCollections::getObjects(id, l1etmiss, begin, end);
0550     }
0551 
0552     void getObjects(size_type filter, Vids& ids, VRl1hfrings& l1hfrings) const {
0553       const size_type begin(l1hfringsSlice(filter).first);
0554       const size_type end(l1hfringsSlice(filter).second);
0555       TriggerRefsCollections::getObjects(ids, l1hfrings, begin, end);
0556     }
0557     void getObjects(size_type filter, int id, VRl1hfrings& l1hfrings) const {
0558       const size_type begin(l1hfringsSlice(filter).first);
0559       const size_type end(l1hfringsSlice(filter).second);
0560       TriggerRefsCollections::getObjects(id, l1hfrings, begin, end);
0561     }
0562 
0563     void getObjects(size_type filter, Vids& ids, VRpfjet& pfjets) const {
0564       const size_type begin(pfjetSlice(filter).first);
0565       const size_type end(pfjetSlice(filter).second);
0566       TriggerRefsCollections::getObjects(ids, pfjets, begin, end);
0567     }
0568     void getObjects(size_type filter, int id, VRpfjet& pfjets) const {
0569       const size_type begin(pfjetSlice(filter).first);
0570       const size_type end(pfjetSlice(filter).second);
0571       TriggerRefsCollections::getObjects(id, pfjets, begin, end);
0572     }
0573 
0574     void getObjects(size_type filter, Vids& ids, VRpftau& pftaus) const {
0575       const size_type begin(pftauSlice(filter).first);
0576       const size_type end(pftauSlice(filter).second);
0577       TriggerRefsCollections::getObjects(ids, pftaus, begin, end);
0578     }
0579     void getObjects(size_type filter, int id, VRpftau& pftaus) const {
0580       const size_type begin(pftauSlice(filter).first);
0581       const size_type end(pftauSlice(filter).second);
0582       TriggerRefsCollections::getObjects(id, pftaus, begin, end);
0583     }
0584 
0585     void getObjects(size_type filter, Vids& ids, VRpfmet& pfmets) const {
0586       const size_type begin(pfmetSlice(filter).first);
0587       const size_type end(pfmetSlice(filter).second);
0588       TriggerRefsCollections::getObjects(ids, pfmets, begin, end);
0589     }
0590     void getObjects(size_type filter, int id, VRpfmet& pfmets) const {
0591       const size_type begin(pfmetSlice(filter).first);
0592       const size_type end(pfmetSlice(filter).second);
0593       TriggerRefsCollections::getObjects(id, pfmets, begin, end);
0594     }
0595 
0596     void getObjects(size_type filter, Vids& ids, VRl1tmuon& l1tmuon) const {
0597       const size_type begin(l1tmuonSlice(filter).first);
0598       const size_type end(l1tmuonSlice(filter).second);
0599       TriggerRefsCollections::getObjects(ids, l1tmuon, begin, end);
0600     }
0601     void getObjects(size_type filter, int id, VRl1tmuon& l1tmuon) const {
0602       const size_type begin(l1tmuonSlice(filter).first);
0603       const size_type end(l1tmuonSlice(filter).second);
0604       TriggerRefsCollections::getObjects(id, l1tmuon, begin, end);
0605     }
0606 
0607     void getObjects(size_type filter, Vids& ids, VRl1tmuonShower& l1tmuonShower) const {
0608       const size_type begin(l1tmuonShowerSlice(filter).first);
0609       const size_type end(l1tmuonShowerSlice(filter).second);
0610       TriggerRefsCollections::getObjects(ids, l1tmuonShower, begin, end);
0611     }
0612     void getObjects(size_type filter, int id, VRl1tmuonShower& l1tmuonShower) const {
0613       const size_type begin(l1tmuonShowerSlice(filter).first);
0614       const size_type end(l1tmuonShowerSlice(filter).second);
0615       TriggerRefsCollections::getObjects(id, l1tmuonShower, begin, end);
0616     }
0617 
0618     void getObjects(size_type filter, Vids& ids, VRl1tegamma& l1tegamma) const {
0619       const size_type begin(l1tegammaSlice(filter).first);
0620       const size_type end(l1tegammaSlice(filter).second);
0621       TriggerRefsCollections::getObjects(ids, l1tegamma, begin, end);
0622     }
0623     void getObjects(size_type filter, int id, VRl1tegamma& l1tegamma) const {
0624       const size_type begin(l1tegammaSlice(filter).first);
0625       const size_type end(l1tegammaSlice(filter).second);
0626       TriggerRefsCollections::getObjects(id, l1tegamma, begin, end);
0627     }
0628 
0629     void getObjects(size_type filter, Vids& ids, VRl1tjet& l1tjet) const {
0630       const size_type begin(l1tjetSlice(filter).first);
0631       const size_type end(l1tjetSlice(filter).second);
0632       TriggerRefsCollections::getObjects(ids, l1tjet, begin, end);
0633     }
0634     void getObjects(size_type filter, int id, VRl1tjet& l1tjet) const {
0635       const size_type begin(l1tjetSlice(filter).first);
0636       const size_type end(l1tjetSlice(filter).second);
0637       TriggerRefsCollections::getObjects(id, l1tjet, begin, end);
0638     }
0639 
0640     /* Phase-2 */
0641     void getObjects(size_type filter, Vids& ids, VRl1ttkmuon& l1ttkmuon) const {
0642       const size_type begin(l1ttkmuonSlice(filter).first);
0643       const size_type end(l1ttkmuonSlice(filter).second);
0644       TriggerRefsCollections::getObjects(ids, l1ttkmuon, begin, end);
0645     }
0646     void getObjects(size_type filter, int id, VRl1ttkmuon& l1ttkmuon) const {
0647       const size_type begin(l1ttkmuonSlice(filter).first);
0648       const size_type end(l1ttkmuonSlice(filter).second);
0649       TriggerRefsCollections::getObjects(id, l1ttkmuon, begin, end);
0650     }
0651 
0652     void getObjects(size_type filter, Vids& ids, VRl1ttkele& l1ttkele) const {
0653       const size_type begin(l1ttkeleSlice(filter).first);
0654       const size_type end(l1ttkeleSlice(filter).second);
0655       TriggerRefsCollections::getObjects(ids, l1ttkele, begin, end);
0656     }
0657     void getObjects(size_type filter, int id, VRl1ttkele& l1ttkele) const {
0658       const size_type begin(l1ttkeleSlice(filter).first);
0659       const size_type end(l1ttkeleSlice(filter).second);
0660       TriggerRefsCollections::getObjects(id, l1ttkele, begin, end);
0661     }
0662 
0663     void getObjects(size_type filter, Vids& ids, VRl1ttkem& l1ttkem) const {
0664       const size_type begin(l1ttkemSlice(filter).first);
0665       const size_type end(l1ttkemSlice(filter).second);
0666       TriggerRefsCollections::getObjects(ids, l1ttkem, begin, end);
0667     }
0668     void getObjects(size_type filter, int id, VRl1ttkem& l1ttkem) const {
0669       const size_type begin(l1ttkemSlice(filter).first);
0670       const size_type end(l1ttkemSlice(filter).second);
0671       TriggerRefsCollections::getObjects(id, l1ttkem, begin, end);
0672     }
0673 
0674     void getObjects(size_type filter, Vids& ids, VRl1tpfjet& l1tpfjet) const {
0675       const size_type begin(l1tpfjetSlice(filter).first);
0676       const size_type end(l1tpfjetSlice(filter).second);
0677       TriggerRefsCollections::getObjects(ids, l1tpfjet, begin, end);
0678     }
0679     void getObjects(size_type filter, int id, VRl1tpfjet& l1tpfjet) const {
0680       const size_type begin(l1tpfjetSlice(filter).first);
0681       const size_type end(l1tpfjetSlice(filter).second);
0682       TriggerRefsCollections::getObjects(id, l1tpfjet, begin, end);
0683     }
0684 
0685     void getObjects(size_type filter, Vids& ids, VRl1tpftau& l1tpftau) const {
0686       const size_type begin(l1tpftauSlice(filter).first);
0687       const size_type end(l1tpftauSlice(filter).second);
0688       TriggerRefsCollections::getObjects(ids, l1tpftau, begin, end);
0689     }
0690     void getObjects(size_type filter, int id, VRl1tpftau& l1tpftau) const {
0691       const size_type begin(l1tpftauSlice(filter).first);
0692       const size_type end(l1tpftauSlice(filter).second);
0693       TriggerRefsCollections::getObjects(id, l1tpftau, begin, end);
0694     }
0695 
0696     void getObjects(size_type filter, Vids& ids, VRl1thpspftau& l1thpspftau) const {
0697       const size_type begin(l1thpspftauSlice(filter).first);
0698       const size_type end(l1thpspftauSlice(filter).second);
0699       TriggerRefsCollections::getObjects(ids, l1thpspftau, begin, end);
0700     }
0701     void getObjects(size_type filter, int id, VRl1thpspftau& l1thpspftau) const {
0702       const size_type begin(l1thpspftauSlice(filter).first);
0703       const size_type end(l1thpspftauSlice(filter).second);
0704       TriggerRefsCollections::getObjects(id, l1thpspftau, begin, end);
0705     }
0706 
0707     void getObjects(size_type filter, Vids& ids, VRl1tpftrack& l1tpftrack) const {
0708       const size_type begin(l1tpftrackSlice(filter).first);
0709       const size_type end(l1tpftrackSlice(filter).second);
0710       TriggerRefsCollections::getObjects(ids, l1tpftrack, begin, end);
0711     }
0712     void getObjects(size_type filter, int id, VRl1tpftrack& l1tpftrack) const {
0713       const size_type begin(l1tpftrackSlice(filter).first);
0714       const size_type end(l1tpftrackSlice(filter).second);
0715       TriggerRefsCollections::getObjects(id, l1tpftrack, begin, end);
0716     }
0717 
0718     void getObjects(size_type filter, Vids& ids, VRl1tp2etsum& l1tp2etsum) const {
0719       const size_type begin(l1tp2etsumSlice(filter).first);
0720       const size_type end(l1tp2etsumSlice(filter).second);
0721       TriggerRefsCollections::getObjects(ids, l1tp2etsum, begin, end);
0722     }
0723     void getObjects(size_type filter, int id, VRl1tp2etsum& l1tp2etsum) const {
0724       const size_type begin(l1tp2etsumSlice(filter).first);
0725       const size_type end(l1tp2etsumSlice(filter).second);
0726       TriggerRefsCollections::getObjects(id, l1tp2etsum, begin, end);
0727     }
0728 
0729     void getObjects(size_type filter, Vids& ids, VRl1ttau& l1ttau) const {
0730       const size_type begin(l1ttauSlice(filter).first);
0731       const size_type end(l1ttauSlice(filter).second);
0732       TriggerRefsCollections::getObjects(ids, l1ttau, begin, end);
0733     }
0734     void getObjects(size_type filter, int id, VRl1ttau& l1ttau) const {
0735       const size_type begin(l1ttauSlice(filter).first);
0736       const size_type end(l1ttauSlice(filter).second);
0737       TriggerRefsCollections::getObjects(id, l1ttau, begin, end);
0738     }
0739 
0740     void getObjects(size_type filter, Vids& ids, VRl1tetsum& l1tetsum) const {
0741       const size_type begin(l1tetsumSlice(filter).first);
0742       const size_type end(l1tetsumSlice(filter).second);
0743       TriggerRefsCollections::getObjects(ids, l1tetsum, begin, end);
0744     }
0745     void getObjects(size_type filter, int id, VRl1tetsum& l1tetsum) const {
0746       const size_type begin(l1tetsumSlice(filter).first);
0747       const size_type end(l1tetsumSlice(filter).second);
0748       TriggerRefsCollections::getObjects(id, l1tetsum, begin, end);
0749     }
0750   };
0751 
0752 }  // namespace trigger
0753 
0754 #endif