00001 #ifndef ParameterSet_EntryNode_h 00002 #define ParameterSet_EntryNode_h 00003 00004 #include "FWCore/ParameterSet/interface/Node.h" 00005 00006 namespace edm { 00007 namespace pset { 00008 00009 /* 00010 ----------------------------------------- 00011 Entries hold: bool, int32, uint32, double, string, and using 00012 This comment may be wrong. 'using' statements create UsingNodes, 00013 according to the rules in pset_parse.y 00014 */ 00015 00016 class EntryNode : public Node 00017 { 00018 public: 00019 EntryNode(const std::string& type, const std::string& name, 00020 const std::string& values, bool untracked, int line=-1); 00021 virtual Node * clone() const { return new EntryNode(*this);} 00022 virtual std::string type() const; 00023 std::string value() const {return value_;} 00024 virtual bool isTracked() const {return tracked_;} 00025 virtual void print(std::ostream& ost, PrintOptions options) const; 00027 virtual void locate(const std::string & s, std::ostream& ost) const; 00028 00029 virtual void accept(Visitor& v) const; 00030 virtual bool isReplaceable() const {return true;} 00031 // keeps the orignal type and tracked-ness 00032 virtual void replaceWith(const ReplaceNode *); 00034 virtual edm::Entry makeEntry() const; 00035 00036 private: 00037 void checkParse(const std::string & s, char * end) const; 00038 std::string type_; 00039 std::string value_; 00040 bool tracked_; 00041 }; 00042 00043 } 00044 } 00045 00046 #endif 00047