TableBase.h
Go to the documentation of this file.
1 #ifndef fhiclcpp_types_detail_TableBase_h
2 #define fhiclcpp_types_detail_TableBase_h
3 
4 #include "cetlib/exempt_ptr.h"
6 
7 namespace fhicl {
8 
9  class ParameterSet;
10 
11  namespace detail {
12 
13  //========================================================
14  class TableBase : public ParameterBase {
15  public:
17  Comment const& comment,
18  par_style const vt,
19  std::function<bool()> maybeUse)
20  : ParameterBase{name, comment, vt, par_type::TABLE, maybeUse}
21  {}
22 
23  std::vector<cet::exempt_ptr<ParameterBase>> const&
24  members() const
25  {
26  return get_members();
27  }
28 
29  private:
30  virtual std::vector<cet::exempt_ptr<ParameterBase>> const& get_members()
31  const = 0;
32  };
33  }
34 }
35 
36 #endif /* fhiclcpp_types_detail_TableBase_h */
37 
38 // Local variables:
39 // mode: c++
40 // End:
const XML_Char * name
Definition: expat.h:151
std::vector< cet::exempt_ptr< ParameterBase > > const & members() const
Definition: TableBase.h:24
virtual std::vector< cet::exempt_ptr< ParameterBase > > const & get_members() const =0
std::string name() const
Definition: ParameterBase.h:49
TableBase(Name const &name, Comment const &comment, par_style const vt, std::function< bool()> maybeUse)
Definition: TableBase.h:16
std::string comment() const
Definition: ParameterBase.h:54