7 return std::make_pair(
false, 0);
12 return std::make_pair(
true, 0);
14 return std::make_pair(
false, 0);
18 return std::make_pair(
true, (
double)
maxIndex());
20 return std::make_pair(
false, 0);
28 return std::make_pair(
true, (
double)i);
31 return std::make_pair(
true, (
double)i - 1);
37 return std::make_pair(
false, 0);
41 return std::make_pair(
true, p);
59 edm::LogError(
"VariableComputer") <<
"redeclaring: " << var <<
" skipping.";
64 arg_.
m.insert(std::make_pair(aName, newVar));
67 std::map<std::string, const ComputedVariable*>::const_iterator it =
iCompute_.find(var);
70 ss <<
"cannot assign: " << var <<
". List of variable declared:\n";
71 for (std::map<std::string, const ComputedVariable*>::const_iterator it =
iCompute_.begin(); it !=
iCompute_.end();
73 ss << it->first << std::endl;
76 it->second->setCache(value);
80 for (std::map<std::string, const ComputedVariable*>::const_iterator it =
iCompute_.begin(); it !=
iCompute_.end();
82 it->second->setNotCompute();
85 std::map<std::string, const ComputedVariable*>::const_iterator it =
iCompute_.find(var);
88 ss <<
"cannot act on: " << var <<
". List of variable declared:\n";
89 for (std::map<std::string, const ComputedVariable*>::const_iterator it =
iCompute_.begin(); it !=
iCompute_.end();
91 ss << it->first << std::endl;
94 it->second->setNotCompute();
static std::vector< std::string > checklist log
ComputedVariable(const CachingVariableFactoryArg &arg, edm::ConsumesCollector &iC)
bool exists(std::string const ¶meterName) const
checks if a parameter exists
VariableComputer(const CachingVariable::CachingVariableFactoryArg &arg, edm::ConsumesCollector &iC)
Exp< T >::type exp(const T &t)
Log< level::Error, false > LogError
const CachingVariable::CachingVariableFactoryArg & arg_
std::vector< double > slots_
unsigned int maxIndex() const
void assign(std::string var, double &value) const
edm::ParameterSet & iConfig
std::map< std::string, const ComputedVariable * > iCompute_
void compute(const edm::Event &iEvent) const override
VariableComputerTest(const CachingVariable::CachingVariableFactoryArg &arg, edm::ConsumesCollector &iC)
CachingVariable::evalType eval(const edm::Event &iEvent) const override
CachingVariable::vMap & m
T getParameter(std::string const &) const
bool compute(const edm::Event &iEvent) const
CachingVariable::evalType eval(const edm::Event &iEvent) const override
void doesNotCompute() const
void declare(std::string var, edm::ConsumesCollector &iC)
std::pair< bool, valueType > evalType