Luiza
v03-01
|
#include <ProcessorMgr.h>
Public Member Functions | |
virtual | ~ProcessorMgr () |
bool | addActiveProcessor (const std::string &processorType, const std::string &processorName, StringParameters *parameters, const std::string condition="true") |
void | removeActiveProcessor (const std::string &name) |
Processor * | getActiveProcessor (const std::string &name) |
Processor * | getProcessor (const std::string &type) |
void | dumpRegisteredProcessors () |
void | dumpRegisteredProcessorsXML () |
virtual void | init () |
Calls init() methods for all active processors. | |
virtual void | startAnalysis (GloriaDataContainer *) |
Calls startAnalysis() methods for all active processors. | |
virtual bool | processData (GloriaDataContainer *) |
Calls processData() and check() methods for all active processors. | |
virtual void | concludeAnalysis (GloriaDataContainer *) |
Calls concludeAnalysis() methods for all active processors. | |
virtual void | end () |
Calls end() methods for all active processors. | |
void | processingLoop (int numEvents) |
virtual void | setProcessorReturnValue (Processor *proc, bool val) |
virtual void | setProcessorReturnValue (Processor *proc, bool val, const std::string &name) |
Static Public Member Functions | |
static ProcessorMgr * | instance () |
Protected Member Functions | |
void | registerProcessor (Processor *processor) |
std::set< std::string > | getAvailableProcessorTypes () |
Processor manager singleton class. Holds references to all registered Processors.
|
virtual |
destructor deletes ProcessorEventSeeder
bool luiza::ProcessorMgr::addActiveProcessor | ( | const std::string & | processorType, |
const std::string & | processorName, | ||
StringParameters * | parameters, | ||
const std::string | condition = "true" |
||
) |
Add a processor of type processorType with name processorName to the list of active processors. Initializes the parameters (if != 0).Add a processor of type processorType with name processorName to the list of active processors including a condition for the execution of the processEvent() method.
References luiza::LogicalExpressions::addCondition(), getProcessor(), and luiza::Processor::newProcessor().
void luiza::ProcessorMgr::dumpRegisteredProcessors | ( | ) |
Dump information of all registered processors to stdout.
void luiza::ProcessorMgr::dumpRegisteredProcessorsXML | ( | ) |
Dump information of all registered processors in XML format to stdout.
Processor * luiza::ProcessorMgr::getActiveProcessor | ( | const std::string & | name | ) |
Return the active processor with the given name. NULL if no processor exists.
|
protected |
Returns a list of all registered processors found
Processor * luiza::ProcessorMgr::getProcessor | ( | const std::string & | type | ) |
Return the processor that has been registered with the given type. NULL if no processor exists.
Referenced by addActiveProcessor().
|
static |
Return the instance of this manager.
Referenced by luiza::Processor::Processor(), and luiza::Processor::setReturnValue().
void luiza::ProcessorMgr::processingLoop | ( | int | numEvents | ) |
Calls readDataSource() for all Processors of type DataSourceProcessor.Loop over all processors to analyse data streem Loop is interupted after given number of passes or when all imputs are finished
References gloria::GloriaDataContainer::ClearTemporaryCollections(), concludeAnalysis(), processData(), and startAnalysis().
|
protected |
Register a processor with the given name.
References luiza::Processor::type().
Referenced by luiza::Processor::Processor().
void luiza::ProcessorMgr::removeActiveProcessor | ( | const std::string & | name | ) |
Remove processor with name from list of active processors.
|
virtual |
Set the return value for the given processor
References luiza::Processor::name(), and luiza::LogicalExpressions::setValue().
Referenced by luiza::Processor::setReturnValue().
|
virtual |
Set the named return value for the given processor
References luiza::Processor::name(), and luiza::LogicalExpressions::setValue().