File indexing completed on 2025-08-06 08:13:21
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011 #ifndef SCORRELATORUTILITIES_PARINFO_H
0012 #define SCORRELATORUTILITIES_PARINFO_H
0013
0014 #pragma GCC diagnostic push
0015 #pragma GCC diagnostic ignored "-Wdeprecated-declarations"
0016
0017
0018 #include <limits>
0019 #include <string>
0020 #include <vector>
0021 #include <utility>
0022
0023 #include <Rtypes.h>
0024 #include <Math/Vector4D.h>
0025
0026 #include <g4main/PHG4Particle.h>
0027
0028 #include <HepMC/GenParticle.h>
0029
0030 #include "Constants.h"
0031
0032 #pragma GCC diagnostic pop
0033
0034
0035 using namespace std;
0036
0037
0038
0039 namespace SColdQcdCorrelatorAnalysis {
0040 namespace Types {
0041
0042
0043
0044
0045
0046
0047
0048
0049
0050 class ParInfo {
0051
0052 private:
0053
0054
0055 int pid = numeric_limits<int>::max();
0056 int status = numeric_limits<int>::max();
0057 int barcode = numeric_limits<int>::max();
0058 int embedID = numeric_limits<int>::max();
0059 float charge = numeric_limits<float>::max();
0060 double mass = numeric_limits<double>::max();
0061 double eta = numeric_limits<double>::max();
0062 double phi = numeric_limits<double>::max();
0063 double ene = numeric_limits<double>::max();
0064 double px = numeric_limits<double>::max();
0065 double py = numeric_limits<double>::max();
0066 double pz = numeric_limits<double>::max();
0067 double pt = numeric_limits<double>::max();
0068 double vx = numeric_limits<double>::max();
0069 double vy = numeric_limits<double>::max();
0070 double vz = numeric_limits<double>::max();
0071 double vr = numeric_limits<double>::max();
0072
0073
0074 void Minimize();
0075 void Maximize();
0076
0077 public:
0078
0079
0080 int GetPID() const {return pid;}
0081 int GetStatus() const {return status;}
0082 int GetBarcode() const {return barcode;}
0083 int GetEmbedID() const {return embedID;}
0084 float GetCharge() const {return charge;}
0085 double GetMass() const {return mass;}
0086 double GetEta() const {return eta;}
0087 double GetPhi() const {return phi;}
0088 double GetEne() const {return ene;}
0089 double GetPX() const {return px;}
0090 double GetPY() const {return py;}
0091 double GetPZ() const {return pz;}
0092 double GetPT() const {return pt;}
0093 double GetVX() const {return vx;}
0094 double GetVY() const {return vy;}
0095 double GetVZ() const {return vz;}
0096 double GetVR() const {return vr;}
0097
0098
0099 void SetPID(const int arg_pid) {pid = arg_pid;}
0100 void SetStatus(const int arg_status) {status = arg_status;}
0101 void SetBarcode(const int arg_barcode) {barcode = arg_barcode;}
0102 void SetEmbedID(const int arg_embedID) {embedID = arg_embedID;}
0103 void SetCharge(const float arg_charge) {charge = arg_charge;}
0104 void SetMass(const double arg_mass) {mass = arg_mass;}
0105 void SetEta(const double arg_eta) {eta = arg_eta;}
0106 void SetPhi(const double arg_phi) {phi = arg_phi;}
0107 void SetEne(const double arg_ene) {ene = arg_ene;}
0108 void SetPX(const double arg_px) {px = arg_px;}
0109 void SetPY(const double arg_py) {py = arg_py;}
0110 void SetPZ(const double arg_pz) {pz = arg_pz;}
0111 void SetPT(const double arg_pt) {pt = arg_pt;}
0112 void SetVX(const double arg_vx) {vx = arg_vx;}
0113 void SetVY(const double arg_vy) {vy = arg_vy;}
0114 void SetVZ(const double arg_vz) {vz = arg_vz;}
0115 void SetVR(const double arg_vr) {vr = arg_vr;}
0116
0117
0118 void Reset();
0119 void SetInfo(const HepMC::GenParticle* particle, const int event);
0120 void SetInfo(const PHG4Particle* particle, const int event);
0121 bool IsInAcceptance(const ParInfo& minimum, const ParInfo& maximum) const;
0122 bool IsInAcceptance(const pair<ParInfo, ParInfo>& range) const;
0123 bool IsFinalState() const;
0124 bool IsHardScatterProduct() const;
0125 bool IsParton() const;
0126 bool IsOutgoingParton() const;
0127
0128
0129 static vector<string> GetListOfMembers();
0130
0131
0132 friend bool operator <(const ParInfo& lhs, const ParInfo& rhs);
0133 friend bool operator >(const ParInfo& lhs, const ParInfo& rhs);
0134 friend bool operator <=(const ParInfo& lhs, const ParInfo& rhs);
0135 friend bool operator >=(const ParInfo& lhs, const ParInfo& rhs);
0136
0137
0138 ParInfo();
0139 ~ParInfo();
0140
0141
0142 ParInfo(const Const::Init init);
0143 ParInfo(HepMC::GenParticle* particle, const int event);
0144 ParInfo(PHG4Particle* particle, const int event);
0145
0146
0147 ClassDefNV(ParInfo, 1)
0148
0149 };
0150
0151
0152
0153
0154
0155 bool operator <(const ParInfo& lhs, const ParInfo& rhs);
0156 bool operator >(const ParInfo& lhs, const ParInfo& rhs);
0157 bool operator <=(const ParInfo& lhs, const ParInfo& rhs);
0158 bool operator >=(const ParInfo& lhs, const ParInfo& rhs);
0159
0160 }
0161 }
0162
0163 #endif
0164
0165