Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 14:23:19

0001 #ifndef L1TMuonEndCap_PtLUTWriter_h
0002 #define L1TMuonEndCap_PtLUTWriter_h
0003 
0004 #include <cstdint>
0005 #include <string>
0006 #include <vector>
0007 
0008 class PtLUTWriter {
0009 public:
0010   explicit PtLUTWriter();
0011   ~PtLUTWriter();
0012 
0013   typedef uint16_t content_t;
0014   typedef uint64_t address_t;
0015   typedef std::vector<content_t> table_t;
0016 
0017   void write(const std::string& lut_full_path, const uint16_t num_, const uint16_t denom_) const;
0018 
0019   void push_back(const content_t& pt);
0020 
0021   void set_version(content_t ver) { version_ = ver; }
0022 
0023   content_t get_version() const { return version_; }
0024 
0025 private:
0026   mutable table_t ptlut_;
0027   content_t version_;
0028   bool ok_;
0029 };
0030 
0031 #endif