#include <MVAComputer.h>
Public Types | |
typedef unsigned int | CacheId |
typedef std::pair< std::string, MVAComputer > | Entry |
Public Member Functions | |
MVAComputer & | add (const std::string &label) |
bool | changed (CacheId old) const |
virtual const MVAComputer & | find (const std::string &label) const |
CacheId | getCacheId () const |
MVAComputerContainer () | |
virtual | ~MVAComputerContainer () |
Private Attributes | |
CacheId | cacheId |
std::vector< Entry > | entries |
Definition at line 188 of file MVAComputer.h.
typedef unsigned int PhysicsTools::Calibration::MVAComputerContainer::CacheId |
Definition at line 199 of file MVAComputer.h.
typedef std::pair<std::string, MVAComputer> PhysicsTools::Calibration::MVAComputerContainer::Entry |
Definition at line 190 of file MVAComputer.h.
PhysicsTools::Calibration::MVAComputerContainer::MVAComputerContainer | ( | ) |
Definition at line 165 of file MVAComputer.cc.
virtual PhysicsTools::Calibration::MVAComputerContainer::~MVAComputerContainer | ( | ) | [inline, virtual] |
Definition at line 193 of file MVAComputer.h.
{}
MVAComputer & PhysicsTools::Calibration::MVAComputerContainer::add | ( | const std::string & | label | ) |
Definition at line 170 of file MVAComputer.cc.
References cacheId, entries, and PhysicsTools::Calibration::getNextMVAComputerContainerCacheId().
{ cacheId = getNextMVAComputerContainerCacheId(); entries.push_back(std::make_pair(label, MVAComputer())); return entries.back().second; }
bool PhysicsTools::Calibration::MVAComputerContainer::changed | ( | CacheId | old | ) | const [inline] |
Definition at line 201 of file MVAComputer.h.
References cacheId.
Referenced by GenericMVAComputerCache::update(), and PhysicsTools::MVAComputerCache::update().
{ return old != cacheId; }
const MVAComputer & PhysicsTools::Calibration::MVAComputerContainer::find | ( | const std::string & | label | ) | const [virtual] |
Reimplemented in PhysicsTools::MVATrainerContainer.
Definition at line 192 of file MVAComputer.cc.
Referenced by PhysicsTools::MVATrainerContainerSave::analyze(), PhysicsTools::MVAModuleHelper< Record, Object, Filler >::init(), GenericMVAComputerCache::update(), and PhysicsTools::MVAComputerCache::update().
{ std::vector<Entry>::const_iterator pos = std::find_if(entries.begin(), entries.end(), Comparator(label)); if (pos == entries.end()) throw cms::Exception("MVAComputerCalibration") << "Calibration record " << label << " not found in MVAComputerContainer." << std::endl; return pos->second; }
CacheId PhysicsTools::Calibration::MVAComputerContainer::getCacheId | ( | ) | const [inline] |
Definition at line 200 of file MVAComputer.h.
References cacheId.
Referenced by GenericMVAComputerCache::update(), and PhysicsTools::MVAComputerCache::update().
{ return cacheId; }
Definition at line 206 of file MVAComputer.h.
Referenced by add(), changed(), and getCacheId().
std::vector<Entry> PhysicsTools::Calibration::MVAComputerContainer::entries [private] |
Definition at line 204 of file MVAComputer.h.