CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
AbsHcalAlgoData.h
Go to the documentation of this file.
1 #ifndef CondFormats_HcalObjects_AbsHcalAlgoData_h_
2 #define CondFormats_HcalObjects_AbsHcalAlgoData_h_
3 
4 #include <typeinfo>
5 
6 //
7 // Classes inheriting from this one are supposed to configure
8 // various Hcal reco algorithms
9 //
11 public:
12  inline virtual ~AbsHcalAlgoData() {}
13 
14  // Comparison operators. Note that they are not virtual and should
15  // not be overriden by derived classes. These operators are very
16  // useful for I/O testing.
17  inline bool operator==(const AbsHcalAlgoData& r) const { return (typeid(*this) == typeid(r)) && this->isEqual(r); }
18  inline bool operator!=(const AbsHcalAlgoData& r) const { return !(*this == r); }
19 
20 protected:
21  // Method needed to compare objects for equality.
22  // Must be implemented by derived classes.
23  virtual bool isEqual(const AbsHcalAlgoData&) const = 0;
24 };
25 
26 #endif // CondFormats_HcalObjects_AbsHcalAlgoData_h_
virtual bool isEqual(const AbsHcalAlgoData &) const =0
bool operator==(const AbsHcalAlgoData &r) const
virtual ~AbsHcalAlgoData()
bool operator!=(const AbsHcalAlgoData &r) const