Pandora
Pandora source code navigator
Loading...
Searching...
No Matches
pandora::AlgorithmManager Class Reference

AlgorithmManager class. More...

#include "AlgorithmManager.h"

Collaboration diagram for pandora::AlgorithmManager:

Public Member Functions

 AlgorithmManager (const Pandora *const pPandora)
 Constructor.
 
 ~AlgorithmManager ()
 Destructor.
 
const StringVectorGetPandoraAlgorithms () const
 Get the list of algorithms to be run by pandora.
 

Private Types

typedef std::map< const std::string, Algorithm *const > AlgorithmMap
 
typedef std::map< const std::string, AlgorithmFactory *const > AlgorithmFactoryMap
 
typedef std::map< const std::string, const std::string > SpecificAlgorithmInstanceMap
 
typedef std::map< const std::string, AlgorithmToolFactory *const > AlgorithmToolFactoryMap
 

Private Member Functions

StatusCode RegisterAlgorithmFactory (const std::string &algorithmType, AlgorithmFactory *const pAlgorithmFactory)
 Register an algorithm factory.
 
StatusCode RegisterAlgorithmToolFactory (const std::string &algorithmToolType, AlgorithmToolFactory *const pAlgorithmToolFactory)
 Register an algorithm tool factory.
 
StatusCode InitializeAlgorithms (const TiXmlHandle *const pXmlHandle)
 Initialize algorithms.
 
StatusCode CreateAlgorithm (TiXmlElement *const pXmlElement, std::string &algorithmName)
 Create an algorithm, via one of the algorithm factories registered with pandora.
 
StatusCode CreateAlgorithmTool (TiXmlElement *const pXmlElement, AlgorithmTool *&pAlgorithmTool)
 Create an algorithm tool, via one of the algorithm tool factories registered with pandora.
 
StatusCode FindSpecificAlgorithmInstance (TiXmlElement *const pXmlElement, std::string &algorithmName, std::string &xmlInstanceLabel) const
 Find the name of a specific algorithm instance, so that it can be re-used.
 
StatusCode ResetForNextEvent ()
 Call the reset callback in all managed algorithms and algorithm tools.
 

Private Attributes

AlgorithmMap m_algorithmMap
 The algorithm map.
 
AlgorithmFactoryMap m_algorithmFactoryMap
 The algorithm factory map.
 
SpecificAlgorithmInstanceMap m_specificAlgorithmInstanceMap
 The specific algorithm instance map.
 
StringVector m_pandoraAlgorithms
 The ordered list of names of top-level algorithms, to be run by pandora.
 
AlgorithmToolVector m_algorithmToolVector
 The algorithm tool vector.
 
AlgorithmToolFactoryMap m_algorithmToolFactoryMap
 The algorithm tool factory map.
 
const Pandora *const m_pPandora
 The pandora instance that will run the algorithms.
 

Friends

class PandoraApiImpl
 
class PandoraContentApiImpl
 
class PandoraImpl
 

Detailed Description

AlgorithmManager class.

Definition at line 30 of file AlgorithmManager.h.

Member Typedef Documentation

◆ AlgorithmFactoryMap

typedef std::map<const std::string, AlgorithmFactory *const> pandora::AlgorithmManager::AlgorithmFactoryMap
private

Definition at line 107 of file AlgorithmManager.h.

◆ AlgorithmMap

typedef std::map<const std::string, Algorithm *const> pandora::AlgorithmManager::AlgorithmMap
private

Definition at line 106 of file AlgorithmManager.h.

◆ AlgorithmToolFactoryMap

typedef std::map<const std::string, AlgorithmToolFactory *const> pandora::AlgorithmManager::AlgorithmToolFactoryMap
private

Definition at line 115 of file AlgorithmManager.h.

◆ SpecificAlgorithmInstanceMap

typedef std::map<const std::string, const std::string> pandora::AlgorithmManager::SpecificAlgorithmInstanceMap
private

Definition at line 108 of file AlgorithmManager.h.

Constructor & Destructor Documentation

◆ AlgorithmManager()

pandora::AlgorithmManager::AlgorithmManager ( const Pandora *const  pPandora)

Constructor.

Parameters
pPandoraaddress of the associated pandora object

Definition at line 26 of file AlgorithmManager.cc.

Here is the call graph for this function:

◆ ~AlgorithmManager()

pandora::AlgorithmManager::~AlgorithmManager ( )

Destructor.

Definition at line 35 of file AlgorithmManager.cc.

Member Function Documentation

◆ CreateAlgorithm()

StatusCode pandora::AlgorithmManager::CreateAlgorithm ( TiXmlElement *const  pXmlElement,
std::string &  algorithmName 
)
private

Create an algorithm, via one of the algorithm factories registered with pandora.

Parameters
pXmlElementaddress of the xml element describing the algorithm type and settings
algorithmNameto receive the name of the algorithm instance

Definition at line 92 of file AlgorithmManager.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ CreateAlgorithmTool()

StatusCode pandora::AlgorithmManager::CreateAlgorithmTool ( TiXmlElement *const  pXmlElement,
AlgorithmTool *&  pAlgorithmTool 
)
private

Create an algorithm tool, via one of the algorithm tool factories registered with pandora.

Parameters
pXmlElementaddress of the xml element describing the algorithm tool type and settings
pAlgorithmToolto receive the address of the algorithm tool instance

Definition at line 150 of file AlgorithmManager.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ FindSpecificAlgorithmInstance()

StatusCode pandora::AlgorithmManager::FindSpecificAlgorithmInstance ( TiXmlElement *const  pXmlElement,
std::string &  algorithmName,
std::string &  xmlInstanceLabel 
) const
private

Find the name of a specific algorithm instance, so that it can be re-used.

Parameters
pXmlElementaddress of the xml element describing the algorithm type and settings
algorithmNameto receive the name of the algorithm instance
xmlInstanceLabelto receive the xml label referring to a specific algorithm instance

Definition at line 194 of file AlgorithmManager.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetPandoraAlgorithms()

const StringVector & pandora::AlgorithmManager::GetPandoraAlgorithms ( ) const
inline

Get the list of algorithms to be run by pandora.

Returns
address of the list pandora algorithms

Definition at line 129 of file AlgorithmManager.h.

Here is the caller graph for this function:

◆ InitializeAlgorithms()

StatusCode pandora::AlgorithmManager::InitializeAlgorithms ( const TiXmlHandle *const  pXmlHandle)
private

Initialize algorithms.

Parameters
pXmlHandleaddress of the relevant xml handle

Definition at line 77 of file AlgorithmManager.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ RegisterAlgorithmFactory()

StatusCode pandora::AlgorithmManager::RegisterAlgorithmFactory ( const std::string &  algorithmType,
AlgorithmFactory *const  pAlgorithmFactory 
)
private

Register an algorithm factory.

Parameters
algorithmTypethe type of algorithm that the factory will create
pAlgorithmFactorythe address of an algorithm factory instance

Definition at line 57 of file AlgorithmManager.cc.

Here is the caller graph for this function:

◆ RegisterAlgorithmToolFactory()

StatusCode pandora::AlgorithmManager::RegisterAlgorithmToolFactory ( const std::string &  algorithmToolType,
AlgorithmToolFactory *const  pAlgorithmToolFactory 
)
private

Register an algorithm tool factory.

Parameters
algorithmToolTypethe type of algorithm tool that the factory will create
pAlgorithmToolFactorythe address of an algorithm tool factory instance

Definition at line 67 of file AlgorithmManager.cc.

Here is the caller graph for this function:

◆ ResetForNextEvent()

StatusCode pandora::AlgorithmManager::ResetForNextEvent ( )
private

Call the reset callback in all managed algorithms and algorithm tools.

Definition at line 225 of file AlgorithmManager.cc.

Here is the caller graph for this function:

Friends And Related Symbol Documentation

◆ PandoraApiImpl

friend class PandoraApiImpl
friend

Definition at line 122 of file AlgorithmManager.h.

◆ PandoraContentApiImpl

friend class PandoraContentApiImpl
friend

Definition at line 123 of file AlgorithmManager.h.

◆ PandoraImpl

friend class PandoraImpl
friend

Definition at line 124 of file AlgorithmManager.h.

Member Data Documentation

◆ m_algorithmFactoryMap

AlgorithmFactoryMap pandora::AlgorithmManager::m_algorithmFactoryMap
private

The algorithm factory map.

Definition at line 111 of file AlgorithmManager.h.

◆ m_algorithmMap

AlgorithmMap pandora::AlgorithmManager::m_algorithmMap
private

The algorithm map.

Definition at line 110 of file AlgorithmManager.h.

◆ m_algorithmToolFactoryMap

AlgorithmToolFactoryMap pandora::AlgorithmManager::m_algorithmToolFactoryMap
private

The algorithm tool factory map.

Definition at line 118 of file AlgorithmManager.h.

◆ m_algorithmToolVector

AlgorithmToolVector pandora::AlgorithmManager::m_algorithmToolVector
private

The algorithm tool vector.

Definition at line 117 of file AlgorithmManager.h.

◆ m_pandoraAlgorithms

StringVector pandora::AlgorithmManager::m_pandoraAlgorithms
private

The ordered list of names of top-level algorithms, to be run by pandora.

Definition at line 113 of file AlgorithmManager.h.

◆ m_pPandora

const Pandora* const pandora::AlgorithmManager::m_pPandora
private

The pandora instance that will run the algorithms.

Definition at line 120 of file AlgorithmManager.h.

◆ m_specificAlgorithmInstanceMap

SpecificAlgorithmInstanceMap pandora::AlgorithmManager::m_specificAlgorithmInstanceMap
private

The specific algorithm instance map.

Definition at line 112 of file AlgorithmManager.h.


The documentation for this class was generated from the following files: