Class Reference for E1039 Core & Analysis Software
SQScaler.h
Go to the documentation of this file.
1 /*
2  * SQScaler.h
3  */
4 #ifndef _H_SQScaler_H_
5 #define _H_SQScaler_H_
6 #include <phool/PHObject.h>
7 #include <iostream>
8 #include <limits>
9 #include <string>
10 
12 
15 class SQScaler : public PHObject {
16 public:
17  typedef enum {
18  UNDEF = -1,
19  BOS = 0,
20  EOS = 1
22 
23  virtual ~SQScaler() {}
24 
25  // PHObject virtual overloads
26 
27  virtual void identify(std::ostream& os = std::cout) const {
28  os << "---SQScaler base class------------" << std::endl;
29  }
30  virtual void Reset() {};
31  virtual int isValid() const {return 0;}
32  virtual SQScaler* Clone() const {return NULL;}
33  virtual PHObject* clone() const {return NULL;}
34 
35  virtual ScalerType_t get_type() const {return UNDEF;}
36  virtual void set_type(const ScalerType_t a) {}
37  virtual std::string get_name() const {return "";}
38  virtual void set_name(const std::string a) {}
39  virtual int get_count() const {return 0;}
40  virtual void set_count(const int a) {}
41 
42 protected:
43  SQScaler() {}
44 
45 private:
46  ClassDef(SQScaler, 1);
47 };
48 
49 #endif /* _H_SQScaler_H_ */
#define NULL
Definition: Pdb.h:9
An SQ interface class to hold the data of one scaler channel.
Definition: SQScaler.h:15
virtual int get_count() const
Return the count of this scaler channel.
Definition: SQScaler.h:39
virtual void set_type(const ScalerType_t a)
Definition: SQScaler.h:36
virtual SQScaler * Clone() const
Definition: SQScaler.h:32
virtual ScalerType_t get_type() const
Return 'BOS' or 'EOS' according to the timing when this channel was read out.
Definition: SQScaler.h:35
virtual void Reset()
Clear Event.
Definition: SQScaler.h:30
virtual void set_count(const int a)
Definition: SQScaler.h:40
virtual ~SQScaler()
Definition: SQScaler.h:23
virtual void identify(std::ostream &os=std::cout) const
Definition: SQScaler.h:27
virtual std::string get_name() const
Return the name of this scaler channel.
Definition: SQScaler.h:37
ScalerType_t
Definition: SQScaler.h:17
@ UNDEF
Definition: SQScaler.h:18
virtual void set_name(const std::string a)
Definition: SQScaler.h:38
virtual PHObject * clone() const
Virtual copy constructor.
Definition: SQScaler.h:33
virtual int isValid() const
isValid returns non zero if object contains vailid data
Definition: SQScaler.h:31
SQScaler()
Definition: SQScaler.h:43