QCoincidence.hh

Go to the documentation of this file.
00001 
00002 #ifndef _Q_COINCIDENCE_HH_
00003 #define _Q_COINCIDENCE_HH_
00004 
00005 #include <list>
00006 #include <map>
00007 
00008 #include "QCoincidentEvent.hh"
00009 
00022 class QCoincidence
00023 {
00024 public:
00025 
00027    QCoincidence();
00028 
00030    virtual ~QCoincidence();
00031 
00038    bool operator<(const QCoincidence& other) const
00039    { return this->GetEvents().front() < other.GetEvents().front(); }
00040 
00042    size_t Size() const { return fEvents.size(); }
00043 
00055    int AddEvent(const QCoincidentEvent& ev);
00056 
00057 
00065    int AddEventFast(const QCoincidentEvent& ev);
00066 
00068    void Clear() { fEvents.clear(); }
00069 
00070 
00072    const std::list<QCoincidentEvent>& GetEvents() const { return fEvents; }
00073 
00075    double GetEnergy() const;
00076 
00078    void AddIndex(int pos, unsigned long long ind);
00079 
00081    const QCoincidentEvent * GetEventByIndex (int pos) const; 
00082 
00084    int GetNIndex() const {return fEventIndex.size();} 
00085 
00086 private:
00087    
00088    std::list<QCoincidentEvent> fEvents;
00089 
00091    std::map<int, unsigned long long> fEventIndex;
00092 };
00093 #endif

Generated on Tue Nov 16 10:49:55 2010 for CUORE Software by  doxygen 1.5.6