Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-08-05 08:18:09

0001 #include "PHG4Particlev1.h"
0002 
0003 PHG4Particlev1::PHG4Particlev1(const std::string &name, const int pid, const double px, const double py, const double pz)
0004   : fname(name)
0005   , fpid(pid)
0006   , fpx(px)
0007   , fpy(py)
0008   , fpz(pz)
0009 {
0010 }
0011 
0012 PHG4Particlev1::PHG4Particlev1(const PHG4Particle *in)
0013   : fname(in->get_name())
0014   , fpid(in->get_pid())
0015   , fpx(in->get_px())
0016   , fpy(in->get_py())
0017   , fpz(in->get_pz())
0018   , barcode(in->get_barcode())
0019 {
0020 }
0021 
0022 void PHG4Particlev1::identify(std::ostream &os) const
0023 {
0024   if (!fname.empty())
0025   {
0026     os << "PHG4Particlev1 name: " << fname;
0027   }
0028   else
0029   {
0030     os << "PHG4Particlev1 name: missing ";
0031   }
0032   os << ", pid: " << fpid
0033      << ", px: " << fpx
0034      << ", py: " << fpy
0035      << ", pz: " << fpz
0036      << ", barcode: " << barcode << std::endl;
0037   return;
0038 }