SourceXtractorPlusPlus  0.15
Please provide a description of the project.
Classes | Public Member Functions | Private Member Functions | Private Attributes | List of all members
SourceXtractor::TaskFactoryRegistry Class Reference

#include <TaskFactoryRegistry.h>

Inheritance diagram for SourceXtractor::TaskFactoryRegistry:
[legend]
Collaboration diagram for SourceXtractor::TaskFactoryRegistry:
[legend]

Classes

class  DuplicateFactoryException
 Exception raised when trying to register 2 TaskFactories that produce the same PropertyType. More...
 

Public Member Functions

virtual ~TaskFactoryRegistry ()=default
 
template<typename FactoryType , typename... Ts>
void registerTaskFactory ()
 
const TaskFactorygetFactory (std::type_index type_id) const
 
virtual void reportConfigDependencies (Euclid::Configuration::ConfigManager &manager) const override
 Registers all the Configuration dependencies. More...
 
virtual void configure (Euclid::Configuration::ConfigManager &manager) override
 Method which should initialize the object. More...
 
void registerPropertyInstances (OutputRegistry &output_registry)
 
- Public Member Functions inherited from SourceXtractor::Configurable
virtual ~Configurable ()=default
 Destructor. More...
 

Private Member Functions

template<typename T >
void registerTaskFactoryImpl (std::shared_ptr< TaskFactory > task_factory)
 
template<typename T , typename T2 , typename... Ts>
void registerTaskFactoryImpl (std::shared_ptr< TaskFactory > task_factory)
 

Private Attributes

std::unordered_set< std::shared_ptr< TaskFactory > > m_task_factories
 
std::unordered_map< std::type_index, std::shared_ptr< TaskFactory > > m_type_task_factories_map
 

Detailed Description

Definition at line 39 of file TaskFactoryRegistry.h.

Constructor & Destructor Documentation

◆ ~TaskFactoryRegistry()

virtual SourceXtractor::TaskFactoryRegistry::~TaskFactoryRegistry ( )
virtualdefault

Member Function Documentation

◆ configure()

void SourceXtractor::TaskFactoryRegistry::configure ( Euclid::Configuration::ConfigManager manager)
overridevirtual

Method which should initialize the object.

The given manager is guaranteed to already be in the initialized state, so all the required Configurations can be accessed using its getConfiguration() method.

Parameters
managerThe manager to get the Configurations from

Implements SourceXtractor::Configurable.

Definition at line 36 of file TaskFactoryRegistry.cpp.

References m_task_factories.

Referenced by SEMain::mainMethod().

◆ getFactory()

const TaskFactory& SourceXtractor::TaskFactoryRegistry::getFactory ( std::type_index  type_id) const
inline

Definition at line 59 of file TaskFactoryRegistry.h.

References m_type_task_factories_map.

◆ registerPropertyInstances()

void SourceXtractor::TaskFactoryRegistry::registerPropertyInstances ( OutputRegistry output_registry)

Definition at line 42 of file TaskFactoryRegistry.cpp.

References m_task_factories.

Referenced by SEMain::mainMethod().

◆ registerTaskFactory()

template<typename FactoryType , typename... Ts>
void SourceXtractor::TaskFactoryRegistry::registerTaskFactory ( )
inline

Definition at line 51 of file TaskFactoryRegistry.h.

References m_task_factories, and registerTaskFactoryImpl().

Referenced by SourceXtractor::BlendedFlagPlugin::registerPlugin(), SourceXtractor::BoundaryFlagPlugin::registerPlugin(), SourceXtractor::CoreThresholdPartitionPlugin::registerPlugin(), SourceXtractor::NDetectedPixelsPlugin::registerPlugin(), SourceXtractor::SaturateFlagPlugin::registerPlugin(), SourceXtractor::SNRRatioPlugin::registerPlugin(), SourceXtractor::SourceFlagsPlugin::registerPlugin(), SourceXtractor::SourceIDsPlugin::registerPlugin(), SourceXtractor::VignetPlugin::registerPlugin(), SourceXtractor::AperturePhotometryPlugin::registerPlugin(), SourceXtractor::AssocModePlugin::registerPlugin(), SourceXtractor::AutoPhotometryPlugin::registerPlugin(), SourceXtractor::DetectionFrameCoordinatesPlugin::registerPlugin(), SourceXtractor::DetectionFrameGroupStampPlugin::registerPlugin(), SourceXtractor::DetectionFrameImagesPlugin::registerPlugin(), SourceXtractor::DetectionFrameInfoPlugin::registerPlugin(), SourceXtractor::DetectionFramePixelValuesPlugin::registerPlugin(), SourceXtractor::DetectionFrameSourceStampPlugin::registerPlugin(), SourceXtractor::ExternalFlagPlugin::registerPlugin(), SourceXtractor::FlexibleModelFittingPlugin::registerPlugin(), SourceXtractor::FluxRadiusPlugin::registerPlugin(), SourceXtractor::GroupInfoPlugin::registerPlugin(), SourceXtractor::GrowthCurvePlugin::registerPlugin(), SourceXtractor::IsophotalFluxPlugin::registerPlugin(), SourceXtractor::JacobianPlugin::registerPlugin(), SourceXtractor::KronRadiusPlugin::registerPlugin(), SourceXtractor::MeasurementFramePlugin::registerPlugin(), SourceXtractor::MeasurementFrameCoordinatesPlugin::registerPlugin(), SourceXtractor::MeasurementFrameGroupRectanglePlugin::registerPlugin(), SourceXtractor::MeasurementFrameImagesPlugin::registerPlugin(), SourceXtractor::MeasurementFrameInfoPlugin::registerPlugin(), SourceXtractor::MeasurementFramePixelCentroidPlugin::registerPlugin(), SourceXtractor::MeasurementFrameRectanglePlugin::registerPlugin(), SourceXtractor::MoffatModelFittingPlugin::registerPlugin(), SourceXtractor::OnnxPlugin::registerPlugin(), SourceXtractor::PeakValuePlugin::registerPlugin(), SourceXtractor::PixelBoundariesPlugin::registerPlugin(), SourceXtractor::PixelCentroidPlugin::registerPlugin(), SourceXtractor::PsfPlugin::registerPlugin(), SourceXtractor::ShapeParametersPlugin::registerPlugin(), and SourceXtractor::WorldCentroidPlugin::registerPlugin().

Here is the call graph for this function:

◆ registerTaskFactoryImpl() [1/2]

template<typename T >
void SourceXtractor::TaskFactoryRegistry::registerTaskFactoryImpl ( std::shared_ptr< TaskFactory task_factory)
inlineprivate

Definition at line 71 of file TaskFactoryRegistry.h.

References m_type_task_factories_map.

Referenced by registerTaskFactory(), and registerTaskFactoryImpl().

◆ registerTaskFactoryImpl() [2/2]

template<typename T , typename T2 , typename... Ts>
void SourceXtractor::TaskFactoryRegistry::registerTaskFactoryImpl ( std::shared_ptr< TaskFactory task_factory)
inlineprivate

Definition at line 81 of file TaskFactoryRegistry.h.

References registerTaskFactoryImpl().

Here is the call graph for this function:

◆ reportConfigDependencies()

void SourceXtractor::TaskFactoryRegistry::reportConfigDependencies ( Euclid::Configuration::ConfigManager manager) const
overridevirtual

Registers all the Configuration dependencies.

Configurable implementations should implement this method to register to the given ConfigManager (using the registerConfiguration() method) all the Configurations they are going to use

Parameters
managerThe manager to register the dependencies to

Implements SourceXtractor::Configurable.

Definition at line 29 of file TaskFactoryRegistry.cpp.

References m_task_factories.

Referenced by SEMain::getConfigParameters().

Member Data Documentation

◆ m_task_factories

std::unordered_set<std::shared_ptr<TaskFactory> > SourceXtractor::TaskFactoryRegistry::m_task_factories
private

◆ m_type_task_factories_map

std::unordered_map<std::type_index, std::shared_ptr<TaskFactory> > SourceXtractor::TaskFactoryRegistry::m_type_task_factories_map
private

Definition at line 87 of file TaskFactoryRegistry.h.

Referenced by getFactory(), and registerTaskFactoryImpl().


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