#include <CachingVariable.h>
Public Member Functions | |
CachingVariable::evalType | eval (const edm::Event &iEvent) const |
SimpleValueVariable (CachingVariableFactoryArg arg) | |
Private Attributes | |
edm::InputTag | src_ |
Definition at line 505 of file CachingVariable.h.
SimpleValueVariable< TYPE >::SimpleValueVariable | ( | CachingVariableFactoryArg | arg | ) | [inline] |
Definition at line 507 of file CachingVariable.h.
References CachingVariable::CachingVariableFactoryArg::m, and CachingVariable::CachingVariableFactoryArg::n.
: CachingVariable("SimpleValueVariable",arg.n,arg.iConfig), src_(edm::Service<InputTagDistributorService>()->retrieve("src",arg.iConfig)) { arg.m[arg.n]=this;}
CachingVariable::evalType SimpleValueVariable< TYPE >::eval | ( | const edm::Event & | iEvent | ) | const [inline, virtual] |
Reimplemented from CachingVariable.
Definition at line 510 of file CachingVariable.h.
References edm::HandleBase::failedToGet(), edm::Event::getByLabel(), edm::HandleBase::isValid(), SimpleValueVariable< TYPE >::src_, and relativeConstraints::value.
{ edm::Handle<TYPE> value; try{ iEvent.getByLabel(src_,value); } catch(...){ return std::make_pair(false,0); } if (value.failedToGet() || !value.isValid()) return std::make_pair(false,0); else return std::make_pair(true, *value); }
edm::InputTag SimpleValueVariable< TYPE >::src_ [private] |
Definition at line 518 of file CachingVariable.h.
Referenced by SimpleValueVariable< TYPE >::eval().