File indexing completed on 2024-04-06 12:19:45
0001 #ifndef L1Trigger_DTTriggerPhase2_DTPattern_h
0002 #define L1Trigger_DTTriggerPhase2_DTPattern_h
0003
0004 #include <tuple>
0005 #include <vector>
0006 #include <iostream>
0007
0008
0009
0010 typedef std::tuple<int, int, int> RefDTPatternHit;
0011
0012
0013 typedef std::tuple<int, int, int> DTPatternIdentifier;
0014
0015 class DTPattern {
0016
0017
0018
0019 public:
0020
0021 DTPattern();
0022 DTPattern(RefDTPatternHit seedUp, RefDTPatternHit seedDown);
0023 DTPattern(int SL1, int SL2, int diff);
0024 virtual ~DTPattern();
0025
0026
0027 void addHit(RefDTPatternHit hit);
0028
0029
0030
0031 int latHitIn(int slId, int chId, int allowedVariance) const;
0032
0033
0034
0035 void setHitUp(int chIdUp) { recoseedUp_ = chIdUp; }
0036 void setHitDown(int chIdDown) { recoseedDown_ = chIdDown; }
0037
0038
0039 DTPatternIdentifier id() const { return id_; }
0040 int sl1() const { return std::get<0>(id_); }
0041 int sl2() const { return std::get<1>(id_); }
0042 int diff() const { return std::get<2>(id_); }
0043 const std::vector<RefDTPatternHit> &genHits() const { return genHits_; }
0044
0045
0046 friend std::ostream &operator<<(std::ostream &out, DTPattern const &p);
0047
0048 private:
0049
0050 RefDTPatternHit seedUp_;
0051 RefDTPatternHit seedDown_;
0052
0053 std::vector<RefDTPatternHit> genHits_;
0054
0055
0056 DTPatternIdentifier id_;
0057
0058 int recoseedUp_;
0059 int recoseedDown_;
0060 const bool debug_ = false;
0061 };
0062
0063 #endif