CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
ComparisonSetter.h
Go to the documentation of this file.
1 #ifndef CommonTools_Utils_ComparisonSetter_h
2 #define CommonTools_Utils_ComparisonSetter_h
3 /* \class reco::parser::ComparisonSetter
4  *
5  * Comparison setter
6  *
7  * \author original version: Chris Jones, Cornell,
8  * adapted by Luca Lista, INFN
9  *
10  * \version $Revision: 1.2 $
11  *
12  */
15 #ifdef BOOST_SPIRIT_DEBUG
16 #include <iostream>
17 #include <string>
18 #endif
19 
20 namespace reco {
21  namespace parser {
22 #ifdef BOOST_SPIRIT_DEBUG
23  template <typename Op> struct cmp_out { static const std::string value; };
24 #endif
25 
26  template<class CompT>
29  void operator()(const char) const {
30 #ifdef BOOST_SPIRIT_DEBUG
31  BOOST_SPIRIT_DEBUG_OUT << "pushing comparison: " << cmp_out<CompT>::value << std::endl;
32 #endif
33  stack_.push_back(boost::shared_ptr<ComparisonBase>(new Comparison<CompT>()));
34  }
35  private:
37  };
38  }
39 }
40 
41 #endif
ComparisonSetter(ComparisonStack &stack)
stack
Definition: svgfig.py:558
void operator()(const char) const
std::vector< boost::shared_ptr< ComparisonBase > > ComparisonStack