GRUTinizer
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
TDetector.h
Go to the documentation of this file.
1 #ifndef _TDETECTOR_H_
2 #define _TDETECTOR_H_
3 
4 #include <vector>
5 
6 #include "TNamed.h"
7 
8 #include "TDetectorHit.h"
9 #include "TRawEvent.h"
10 //class TRawEvent;
11 class TSmartBuffer;
12 
13 
14 class TDetector : public TNamed {
15 public:
16  TDetector();
17  TDetector(const char *name,const char *title="");
18  virtual ~TDetector();
19 
20  bool AddRawData(const TRawEvent& buf);
21 
22  virtual void Copy(TObject& obj) const;
23  virtual void Clear(Option_t *opt = "" );
24  virtual void Print(Option_t *opt = "" ) const;
25  virtual int Compare(const TObject& obj) const;
26 
27  int Build();
28  virtual void InsertHit(const TDetectorHit&) { AbstractMethod("InsertHit()"); }
29  virtual TDetectorHit& GetHit(int i) { AbstractMethod("GetHit()"); }
30 
31  int Size() const { return fSize; }
32 
33 
34  Long_t Timestamp() const { return fTimestamp; }
36 
37 protected:
38  #ifndef __CINT__
39  std::vector<TRawEvent> raw_data;
40  #endif
41 
42  int fSize;
43  Long_t fTimestamp;
44 
45 private:
46  virtual int BuildHits() { AbstractMethod("BuildHits()"); }
47 
48 
50 };
51 
52 #endif