CMS 3D CMS Logo

IfExistsDescription.h
Go to the documentation of this file.
1 #ifndef FWCore_ParameterSet_IfExistsDescription_h
2 #define FWCore_ParameterSet_IfExistsDescription_h
3 
5 
7 
8 #include <memory>
9 #include <iosfwd>
10 #include <set>
11 #include <string>
12 
13 namespace edm {
14 
15  class ParameterSet;
16  class DocFormatHelper;
17 
19  public:
20  IfExistsDescription(ParameterDescriptionNode const& node_left, ParameterDescriptionNode const& node_right);
21 
22  IfExistsDescription(std::unique_ptr<ParameterDescriptionNode> node_left,
23  ParameterDescriptionNode const& node_right);
24 
26  std::unique_ptr<ParameterDescriptionNode> node_right);
27 
28  IfExistsDescription(std::unique_ptr<ParameterDescriptionNode> node_left,
29  std::unique_ptr<ParameterDescriptionNode> node_right);
30 
31  ParameterDescriptionNode* clone() const override { return new IfExistsDescription(*this); }
32 
33  private:
34  void checkAndGetLabelsAndTypes_(std::set<std::string>& usedLabels,
35  std::set<ParameterTypes>& parameterTypes,
36  std::set<ParameterTypes>& wildcardTypes) const override;
37 
38  void validate_(ParameterSet& pset, std::set<std::string>& validatedLabels, bool optional) const override;
39 
40  void writeCfi_(std::ostream& os, bool& startWithComma, int indentation, bool& wroteSomething) const override;
41 
42  void print_(std::ostream& os, bool optional, bool writeToCfi, DocFormatHelper& dfh) const override;
43 
44  bool hasNestedContent_() const override { return true; }
45 
46  void printNestedContent_(std::ostream& os, bool optional, DocFormatHelper& dfh) const override;
47 
48  bool exists_(ParameterSet const& pset) const override;
49 
50  bool partiallyExists_(ParameterSet const& pset) const override;
51 
52  int howManyXORSubNodesExist_(ParameterSet const& pset) const override;
53 
54  void throwIfDuplicateLabels(std::set<std::string> const& labelsLeft,
55  std::set<std::string> const& labelsRight) const;
56 
57  void throwIfDuplicateTypes(std::set<ParameterTypes> const& types1, std::set<ParameterTypes> const& types2) const;
58 
61  };
62 } // namespace edm
63 #endif
bool exists_(ParameterSet const &pset) const override
bool partiallyExists_(ParameterSet const &pset) const override
void print_(std::ostream &os, bool optional, bool writeToCfi, DocFormatHelper &dfh) const override
void printNestedContent_(std::ostream &os, bool optional, DocFormatHelper &dfh) const override
ParameterDescriptionNode * clone() const override
IfExistsDescription(ParameterDescriptionNode const &node_left, ParameterDescriptionNode const &node_right)
void throwIfDuplicateLabels(std::set< std::string > const &labelsLeft, std::set< std::string > const &labelsRight) const
void validate_(ParameterSet &pset, std::set< std::string > &validatedLabels, bool optional) const override
void throwIfDuplicateTypes(std::set< ParameterTypes > const &types1, std::set< ParameterTypes > const &types2) const
edm::value_ptr< ParameterDescriptionNode > node_right_
edm::value_ptr< ParameterDescriptionNode > node_left_
void checkAndGetLabelsAndTypes_(std::set< std::string > &usedLabels, std::set< ParameterTypes > &parameterTypes, std::set< ParameterTypes > &wildcardTypes) const override
void writeCfi_(std::ostream &os, bool &startWithComma, int indentation, bool &wroteSomething) const override
HLT enums.
int howManyXORSubNodesExist_(ParameterSet const &pset) const override
bool hasNestedContent_() const override