/* * CbmRichDigi.h * * Created on: Dec 17, 2015 * Author: slebedev * Modified on: Mar 25, 2019 * e.ovcharenko */ //TODO implement copy constructor and operator= ? #include // for ClassDef #include // for Double_t, Int_t #include // for basic_string, string #include "CbmDefs.h" // for kRich #ifndef DATA_RICH_CBMRICHDIGI_H_ #define DATA_RICH_CBMRICHDIGI_H_ class CbmRichDigi { public: CbmRichDigi(); CbmRichDigi(Int_t addr, Double_t time, Double_t tot); ~CbmRichDigi(); /* * \brief Inherited from CbmDigi * @value Unique address of pixel channel */ Int_t GetAddress() const { return fAddress; } /** @brief Charge ** @return Returns TOT as charge ** ** Alias for GetToT, conversion factor should be added if needed. ** For compatibility with template methods **/ Double_t GetCharge() const { return fToT; } /** @brief Class name (static) ** @return CbmRichDigi **/ static const char* GetClassName() { return "CbmRichDigi"; } /** @brief System identifier ** @return kRich (ECbmModuleId), static **/ static ECbmModuleId GetSystem() { return ECbmModuleId::kRich; } /* * @brief Time * @value Time [ns] */ Double_t GetTime() const { return fTime; } /* * \brief Get Time-over-threshold * @value Time-over-threshold, pulse width [ns] */ Double_t GetToT() const { return fToT; } /* * \brief Set pixel Address */ void SetAddress(Int_t address) { fAddress = address; } /* * \brief Set pixel Address */ void SetTime(Double_t time) { fTime = time; } std::string ToString() const { return std::string{""}; } private: /** * \brief Unique pixel address */ Int_t fAddress; /** * \brief Leading (rising) edge time */ Double_t fTime; /** * \brief Time-over-threshold, pulse width */ Double_t fToT; ClassDefNV(CbmRichDigi, 3); }; #endif /* DATA_RICH_CBMRICHDIGI_H_ */