CMS 3D CMS Logo

formulaEvaluatorBase.cc
Go to the documentation of this file.
1 // -*- C++ -*-
2 //
3 // Package: CommonTools/Utils
4 // Class : reco::formula::EvaluatorBase
5 //
6 // Implementation:
7 // [Notes on implementation]
8 //
9 // Original Author: Christopher Jones
10 // Created: Wed, 23 Sep 2015 16:26:03 GMT
11 //
12 
13 // system include files
14 #include <algorithm>
15 
16 // user include files
18 
19 //
20 // constants, enums and typedefs
21 //
22 
23 //
24 // static data member definitions
25 //
26 
27 //
28 // constructors and destructor
29 //
30 reco::formula::EvaluatorBase::EvaluatorBase() : m_precedence(static_cast<unsigned int>(Precedence::kFunction)) {}
31 
32 reco::formula::EvaluatorBase::EvaluatorBase(Precedence iPrec) : m_precedence(static_cast<unsigned int>(iPrec)) {}
33 
35 
36 std::vector<std::string> reco::formula::shiftAST(std::vector<std::string> child) {
37  for (auto& c : child) {
38  c.insert(c.begin(), '.');
39  }
40  return child;
41 }
std::vector< std::string > shiftAST(std::vector< std::string > child)