CMS 3D CMS Logo

L1GctEmLeafCard.h
Go to the documentation of this file.
1 #ifndef L1GCTELECTRONLEAFCARD_H_
2 #define L1GCTELECTRONLEAFCARD_H_
3 
6 
7 #include <vector>
8 #include <ostream>
9 
21 public:
22  static const unsigned N_SORTERS;
23 
24 public:
26  L1GctEmLeafCard(int id);
29  ~L1GctEmLeafCard() override;
32  void reset();
35  void fetchInput() override;
38  void process() override;
41  void setBxRange(const int firstBx, const int numberOfBx);
44  void setNextBx(const int bxnum);
47  int id() { return m_id; }
50  std::vector<L1GctEmCand> getOutputIsoEmCands(int fpga);
53  std::vector<L1GctEmCand> getOutputNonIsoEmCands(int fpga);
56  friend std::ostream& operator<<(std::ostream& s, const L1GctEmLeafCard& card);
57 
62 
63 protected:
65  void resetProcessor() override {}
66  void resetPipelines() override {}
67 
69  void setupObjects() override {}
70 
71 private:
73  int m_id;
76  std::vector<L1GctElectronSorter*> m_sorters;
77 };
78 
79 std::ostream& operator<<(std::ostream& s, const L1GctEmLeafCard& card);
80 #endif /*L1GCTELECTRONLEAFCARD_H_*/
std::vector< L1GctEmCand > getOutputNonIsoEmCands(int fpga)
get the output candidates
L1GctElectronSorter * getNonIsoElectronSorterU1()
void resetPipelines() override
void setupObjects() override
Initialise inputs with null objects for the correct bunch crossing if required.
L1GctElectronSorter * getNonIsoElectronSorterU2()
void fetchInput() override
fetch input data
void resetProcessor() override
Separate reset methods for the processor itself and any data stored in pipelines. ...
friend std::ostream & operator<<(std::ostream &s, const L1GctEmLeafCard &card)
overload of cout operator
void setNextBx(const int bxnum)
clear input data buffers and process a new bunch crossing
ABC for a GCT trigger data processing unit.
std::vector< L1GctEmCand > getOutputIsoEmCands(int fpga)
get the output candidates
static const unsigned N_SORTERS
int m_id
card ID (0 or 1)
int id()
get ID
L1GctElectronSorter * getIsoElectronSorterU1()
Class that sorts electron candidates.
std::vector< L1GctElectronSorter * > m_sorters
processing - 0,2 are iso sorters, 1,3 are non-iso
~L1GctEmLeafCard() override
destruct
std::ostream & operator<<(std::ostream &s, const L1GctEmLeafCard &card)
void reset()
clear internal trigger data buffers
void setBxRange(const int firstBx, const int numberOfBx)
define the bunch crossing range to process
L1GctElectronSorter * getIsoElectronSorterU2()
Emulates a leaf card programmed for electron sorting.
L1GctEmLeafCard(int id)
construct with ID
void process() override
process the event