Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 14:21:22

0001 #ifndef IORAWDATA_CALOPATTERNS_HCALFIBERPATTERN_H
0002 #define IORAWDATA_CALOPATTERNS_HCALFIBERPATTERN_H 1
0003 
0004 #include "DataFormats/HcalDigi/interface/HcalQIESample.h"
0005 #include "DataFormats/HcalDetId/interface/HcalElectronicsId.h"
0006 #include <string>
0007 #include <map>
0008 #include <vector>
0009 
0010 /** \class HcalFiberPattern
0011   *  
0012   * \author J. Mans - Minnesota
0013   */
0014 class HcalFiberPattern {
0015 public:
0016   HcalFiberPattern(const std::map<std::string, std::string>& params, const std::vector<uint32_t>& data);
0017   std::vector<HcalQIESample> getSamples(int bunch, int npresamples, int nsamples, int fiberChan);
0018   HcalElectronicsId getId(int fiberChan);
0019   int crate() const { return crate_; }
0020   int slot() const { return slot_; }
0021   int fiber() const { return fiber_; }
0022 
0023 private:
0024   HcalQIESample unpack(int bc, int fc);
0025   int crate_, slot_, tb_, fiber_, spigot_, dcc_;
0026   std::vector<uint32_t> pattern_;
0027 };
0028 
0029 #endif