File indexing completed on 2023-03-17 10:50:26
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012 #ifndef L1TMUPHASE2GMTSTUB_H
0013 #define L1TMUPHASE2GMTSTUB_H
0014
0015
0016
0017
0018 #include <iosfwd>
0019 #include <vector>
0020
0021
0022
0023
0024
0025
0026
0027
0028
0029
0030 #include "DataFormats/L1Trigger/interface/BXVector.h"
0031 #include "DataFormats/Common/interface/Ref.h"
0032 #include "FWCore/MessageLogger/interface/MessageLogger.h"
0033
0034
0035
0036
0037
0038 namespace l1t {
0039
0040 class MuonStub;
0041
0042 typedef std::vector<MuonStub> MuonStubCollection;
0043 typedef edm::Ref<MuonStubCollection> MuonStubRef;
0044 typedef std::vector<edm::Ref<MuonStubCollection> > MuonStubRefVector;
0045
0046 class MuonStub {
0047 public:
0048
0049 MuonStub();
0050
0051
0052 MuonStub(int etaRegion,
0053 int phiRegion,
0054 int depthRegion,
0055 uint tfLayer,
0056 int coord1,
0057 int coord2,
0058 int id,
0059 int bx,
0060 int quality,
0061 int eta1 = 0,
0062 int eta2 = 0,
0063 int etaQuality = -1,
0064 int type = 0);
0065 ~MuonStub();
0066
0067 inline int etaRegion() const { return etaRegion_; }
0068
0069 inline int phiRegion() const { return phiRegion_; }
0070
0071 inline int depthRegion() const { return depthRegion_; }
0072
0073 inline uint tfLayer() const { return tfLayer_; }
0074
0075 inline int coord1() const { return coord1_; }
0076
0077 inline int coord2() const { return coord2_; }
0078
0079 inline int quality() const { return quality_; }
0080
0081 inline int id() const { return id_; }
0082
0083 inline int bxNum() const { return bxNum_; }
0084
0085
0086 inline int eta1() const { return eta1_; }
0087 inline int eta2() const { return eta2_; }
0088
0089 inline int etaQuality() const { return etaQuality_; }
0090
0091 inline int type() const { return type_; }
0092
0093 inline bool isBarrel() const { return (type_ == 1); }
0094 inline bool isEndcap() const { return (type_ == 0); }
0095
0096 inline double offline_coord1() const { return offline_coord1_; }
0097 inline double offline_coord2() const { return offline_coord2_; }
0098 inline double offline_eta1() const { return offline_eta1_; }
0099 inline double offline_eta2() const { return offline_eta2_; }
0100
0101 void setOfflineQuantities(double coord1, double coord2, double eta1, double eta2) {
0102 offline_coord1_ = coord1;
0103 offline_coord2_ = coord2;
0104 offline_eta1_ = eta1;
0105 offline_eta2_ = eta2;
0106 }
0107 void setEta(int eta1, int eta2, int etaQ) {
0108 eta1_ = eta1;
0109 eta2_ = eta2;
0110 etaQuality_ = etaQ;
0111 }
0112
0113 void setID(int id) { id_ = id; }
0114
0115 bool operator==(const MuonStub&) const;
0116
0117 bool operator!=(const MuonStub&) const;
0118
0119 void print() const;
0120
0121 private:
0122 int etaRegion_;
0123 int phiRegion_;
0124 int depthRegion_;
0125 uint tfLayer_;
0126 int coord1_;
0127 int coord2_;
0128 int id_;
0129 int quality_;
0130 int bxNum_;
0131 int eta1_;
0132 int eta2_;
0133 int etaQuality_;
0134 int type_;
0135
0136 double offline_coord1_;
0137 double offline_coord2_;
0138 double offline_eta1_;
0139 double offline_eta2_;
0140 };
0141
0142 }
0143 #endif