CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
LocationDef.h
Go to the documentation of this file.
1 #ifndef LOCATIONDEF_H
2 #define LOCATIONDEF_H
3 
4 #include <string>
5 #include <stdexcept>
6 
8 
12 class LocationDef : public IDef {
13 public:
14  friend class EcalCondDBInterface;
15 
16  LocationDef();
17  ~LocationDef() override;
18 
19  // Methods for user data
20  std::string getLocation() const;
21  void setLocation(std::string loc);
22 
23  // Methods from IUniqueDBObject
24  int fetchID() noexcept(false) override;
25  void setByID(int id) noexcept(false) override;
26 
27  inline bool operator==(const LocationDef& l) const { return m_loc == l.m_loc; }
28  inline bool operator!=(const LocationDef& l) const { return m_loc != l.m_loc; }
29 
30 protected:
31  // User data for this def
33 
34  void fetchAllDefs(std::vector<LocationDef>* fillVec) noexcept(false);
35 };
36 
37 #endif
void fetchAllDefs(std::vector< LocationDef > *fillVec) noexcept(false)
Definition: LocationDef.cc:80
~LocationDef() override
Definition: LocationDef.cc:16
bool operator!=(const LocationDef &l) const
Definition: LocationDef.h:28
#define override(base_class)
void setByID(int id) noexcept(false) override
Definition: LocationDef.cc:57
std::string getLocation() const
Definition: LocationDef.cc:18
Definition: IDef.h:11
std::string m_loc
Definition: LocationDef.h:32
int fetchID() noexcept(false) override
Definition: LocationDef.cc:27
void setLocation(std::string loc)
Definition: LocationDef.cc:20