CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
AllowedLabelsDescriptionBase.h
Go to the documentation of this file.
1 #ifndef FWCore_ParameterSet_AllowedLabelsDescriptionBase_h
2 #define FWCore_ParameterSet_AllowedLabelsDescriptionBase_h
3 
6 
7 #include <vector>
8 #include <string>
9 #include <set>
10 #include <iosfwd>
11 
12 namespace edm {
13 
14  class ParameterSet;
15 
17  public:
18 
20 
21  ParameterTypes type() const { return type_; }
22  bool isTracked() const { return isTracked_; }
23 
24  protected:
25 
27 
29 
30  void printNestedContentBase_(std::ostream & os,
31  bool optional,
32  DocFormatHelper & dfh);
33 
34  private:
35 
36  virtual void checkAndGetLabelsAndTypes_(std::set<std::string> & usedLabels,
37  std::set<ParameterTypes> & parameterTypes,
38  std::set<ParameterTypes> & wildcardTypes) const;
39 
40  virtual void validate_(ParameterSet & pset,
41  std::set<std::string> & validatedLabels,
42  bool optional) const;
43 
44  virtual void writeCfi_(std::ostream & os,
45  bool & startWithComma,
46  int indentation,
47  bool & wroteSomething) const;
48 
49 
50  virtual void print_(std::ostream & os,
51  bool optional,
52  bool writeToCfi,
53  DocFormatHelper & dfh);
54 
55  virtual bool hasNestedContent_();
56 
57  virtual void printNestedContent_(std::ostream & os,
58  bool optional,
59  DocFormatHelper & dfh);
60 
61  virtual bool exists_(ParameterSet const& pset) const;
62 
63  virtual bool partiallyExists_(ParameterSet const& pset) const;
64 
65  virtual int howManyXORSubNodesExist_(ParameterSet const& pset) const;
66 
67  virtual void validateAllowedLabel_(std::string const& allowedLabel,
69  std::set<std::string> & validatedLabels) const = 0;
70 
73  bool isTracked_;
74  };
75 }
76 
77 #endif
void printNestedContentBase_(std::ostream &os, bool optional, DocFormatHelper &dfh)
virtual bool partiallyExists_(ParameterSet const &pset) const
AllowedLabelsDescriptionBase(std::string const &label, ParameterTypes iType, bool isTracked)
virtual void checkAndGetLabelsAndTypes_(std::set< std::string > &usedLabels, std::set< ParameterTypes > &parameterTypes, std::set< ParameterTypes > &wildcardTypes) const
virtual void validateAllowedLabel_(std::string const &allowedLabel, ParameterSet &pset, std::set< std::string > &validatedLabels) const =0
virtual bool exists_(ParameterSet const &pset) const
virtual void validate_(ParameterSet &pset, std::set< std::string > &validatedLabels, bool optional) const
ParameterDescription< std::vector< std::string > > parameterHoldingLabels_
virtual void writeCfi_(std::ostream &os, bool &startWithComma, int indentation, bool &wroteSomething) const
virtual void printNestedContent_(std::ostream &os, bool optional, DocFormatHelper &dfh)
virtual void print_(std::ostream &os, bool optional, bool writeToCfi, DocFormatHelper &dfh)
virtual int howManyXORSubNodesExist_(ParameterSet const &pset) const