//----------------------------------------------------------- // File and Version Information: // $Id$ // // Description: // Implementation of class TpcSignal // see TpcSignal.h for details // // Environment: // Software developed for the PANDA Detector at FAIR. // // Author List: // Sebastian Neubert TUM (original author) // // //----------------------------------------------------------- // This Class' Header ------------------ #include "TpcSignal.h" // C/C++ Headers ---------------------- #include // Collaborating Class Headers -------- #include "TpcAvalanche.h" // Class Member definitions ----------- ClassImp(TpcSignal) TpcSignal::TpcSignal() : _t(0),_amp(0),_padId(0),_mcTrackId(0),_mcHitId(0),_mcEventId(0),_mother(0) {;} TpcSignal::TpcSignal(double t, double Amp, unsigned int PadID, unsigned int EventID, TpcAvalanche* Mo) : _t(t),_amp(Amp),_padId(PadID),_mcTrackId(0),_mcHitId(0),_mcEventId(EventID),_mother(Mo) {;} unsigned int TpcSignal::mcTrackId() const { if(_mother==0) return _mcTrackId; return _mother->mcTrackId(); } unsigned int TpcSignal::mcHitId() const { if(_mother==0) return _mcHitId; return _mother->mcHitId(); } bool operator== (const TpcSignal& lhs, const TpcSignal& rhs) { return fabs(lhs._t-rhs._t)<1E-4 && lhs._padId==rhs._padId; } bool operator< (const TpcSignal& lhs, const TpcSignal& rhs) { return lhs._t