Class Reference for E1039 Core & Analysis Software
SQParamDeco.h
Go to the documentation of this file.
1 
5 #ifndef _H_SQ_PARAM_DECO_H_
6 #define _H_SQ_PARAM_DECO_H_
7 #include <string>
8 #include <map>
9 #include <iostream>
10 #include <phool/PHObject.h>
11 
13 
16 class SQParamDeco : public PHObject {
17 public:
18  typedef std::map<std::string, std::string> ParamMap;
19  typedef ParamMap::const_iterator ParamConstIter;
20  typedef ParamMap::iterator ParamIter;
21 
22  virtual ~SQParamDeco() {}
23 
24  virtual void identify(std::ostream& os = std::cout) const = 0;
25  virtual int isValid() const = 0;
26  virtual SQParamDeco* Clone() const = 0;
27  virtual void Reset() = 0;
28 
29  virtual bool has_variable(const std::string name) const = 0;
30  virtual std::string get_variable(const std::string name) const = 0;
31  virtual void set_variable(const std::string name, const std::string value) = 0;
32 
33  virtual ParamConstIter begin() const = 0;
34  virtual ParamConstIter end() const = 0;
35  virtual unsigned int size() const = 0;
36 
37 protected:
39 
40 private:
41  ClassDef(SQParamDeco, 1);
42 };
43 
44 #endif /* _H_SQ_PARAM_DECO_H_ */
SQParamDeco.h.
Definition: SQParamDeco.h:16
virtual ~SQParamDeco()
Definition: SQParamDeco.h:22
virtual int isValid() const =0
isValid returns non zero if object contains vailid data
virtual void Reset()=0
Clear Event.
ParamMap::iterator ParamIter
Definition: SQParamDeco.h:20
virtual unsigned int size() const =0
Return the number of variables held.
virtual ParamConstIter end() const =0
Return the end iterator.
virtual bool has_variable(const std::string name) const =0
Return 'true' if a variable having 'name' exists.
ParamMap::const_iterator ParamConstIter
Definition: SQParamDeco.h:19
virtual void identify(std::ostream &os=std::cout) const =0
virtual std::string get_variable(const std::string name) const =0
Return the value of a variable having 'name'. Return "" if no variable exists.
virtual ParamConstIter begin() const =0
Return the begin iterator.
virtual void set_variable(const std::string name, const std::string value)=0
virtual SQParamDeco * Clone() const =0
std::map< std::string, std::string > ParamMap
Definition: SQParamDeco.h:18