SourceXtractorPlusPlus 0.21
SourceXtractor++, the next generation SExtractor
Loading...
Searching...
No Matches
Public Member Functions | Protected Member Functions | Private Attributes | List of all members
SourceXtractor::SourceWithOnDemandProperties Class Reference

#include <SourceWithOnDemandProperties.h>

Inheritance diagram for SourceXtractor::SourceWithOnDemandProperties:
Inheritance graph
[legend]
Collaboration diagram for SourceXtractor::SourceWithOnDemandProperties:
Collaboration graph
[legend]

Public Member Functions

virtual ~SourceWithOnDemandProperties ()=default
 Destructor.
 
 SourceWithOnDemandProperties (const SourceWithOnDemandProperties &)=delete
 
SourceWithOnDemandPropertiesoperator= (const SourceWithOnDemandProperties &)=delete
 
 SourceWithOnDemandProperties (SourceWithOnDemandProperties &&)=delete
 
SourceWithOnDemandPropertiesoperator= (SourceWithOnDemandProperties &&)=delete
 
 SourceWithOnDemandProperties (std::shared_ptr< const TaskProvider > task_provider)
 Constructor.
 
template<typename PropertyType >
const PropertyTypegetProperty (unsigned int index=0) const
 Convenience template method to call getProperty() with a more user-friendly syntax.
 
virtual const PropertygetProperty (const PropertyId &property_id) const=0
 
template<typename PropertyType , typename ... Args>
void setProperty (Args... args)
 
virtual void setProperty (std::unique_ptr< Property > property, const PropertyId &property_id)=0
 
- Public Member Functions inherited from SourceXtractor::SourceInterface
virtual ~SourceInterface ()=default
 Destructor.
 
template<typename PropertyType >
const PropertyTypegetProperty (unsigned int index=0) const
 Convenience template method to call getProperty() with a more user-friendly syntax.
 
template<typename PropertyType , typename ... Args>
void setIndexedProperty (std::size_t index, Args... args)
 Convenience template method to call setProperty() with a more user-friendly syntax.
 
template<typename PropertyType , typename ... Args>
void setProperty (Args... args)
 

Protected Member Functions

const PropertygetProperty (const PropertyId &property_id) const override
 
void setProperty (std::unique_ptr< Property > property, const PropertyId &property_id) override
 

Private Attributes

std::shared_ptr< const TaskProviderm_task_provider
 
PropertyHolder m_property_holder
 

Detailed Description

Provides getProperty() and setProperty() implementations which use a TaskProvider to compute the non already available properties on demand.

Definition at line 43 of file SourceWithOnDemandProperties.h.

Constructor & Destructor Documentation

◆ ~SourceWithOnDemandProperties()

virtual SourceXtractor::SourceWithOnDemandProperties::~SourceWithOnDemandProperties ( )
virtualdefault

Destructor.

◆ SourceWithOnDemandProperties() [1/3]

SourceXtractor::SourceWithOnDemandProperties::SourceWithOnDemandProperties ( const SourceWithOnDemandProperties & )
delete

◆ SourceWithOnDemandProperties() [2/3]

SourceXtractor::SourceWithOnDemandProperties::SourceWithOnDemandProperties ( SourceWithOnDemandProperties && )
delete

◆ SourceWithOnDemandProperties() [3/3]

SourceXtractor::SourceWithOnDemandProperties::SourceWithOnDemandProperties ( std::shared_ptr< const TaskProvider > task_provider)
explicit

Constructor.

Definition at line 35 of file SourceWithOnDemandProperties.cpp.

Member Function Documentation

◆ getProperty() [1/3]

const Property & SourceXtractor::SourceWithOnDemandProperties::getProperty ( const PropertyId & property_id) const
overrideprotectedvirtual

Returns a reference to the requested property. The property may be computed if needed Throws a PropertyNotFoundException if the property cannot be provided.

Implements SourceXtractor::SourceInterface.

Definition at line 39 of file SourceWithOnDemandProperties.cpp.

References Elements::Logging::debug(), SourceXtractor::PropertyHolder::getProperty(), SourceXtractor::PropertyHolder::isPropertySet(), Euclid::Configuration::logger, m_property_holder, and m_task_provider.

Here is the call graph for this function:

◆ getProperty() [2/3]

virtual const Property & SourceXtractor::SourceInterface::getProperty ( const PropertyId & property_id) const
virtual

Returns a reference to the requested property. The property may be computed if needed Throws a PropertyNotFoundException if the property cannot be provided.

Implements SourceXtractor::SourceInterface.

◆ getProperty() [3/3]

template<typename PropertyType >
const PropertyType & SourceXtractor::SourceInterface::getProperty ( unsigned int index = 0) const
inline

Convenience template method to call getProperty() with a more user-friendly syntax.

Definition at line 57 of file SourceInterface.h.

◆ operator=() [1/2]

SourceWithOnDemandProperties & SourceXtractor::SourceWithOnDemandProperties::operator= ( const SourceWithOnDemandProperties & )
delete

◆ operator=() [2/2]

SourceWithOnDemandProperties & SourceXtractor::SourceWithOnDemandProperties::operator= ( SourceWithOnDemandProperties && )
delete

◆ setProperty() [1/3]

template<typename PropertyType , typename ... Args>
void SourceXtractor::SourceInterface::setProperty ( Args... args)
inline

Definition at line 72 of file SourceInterface.h.

◆ setProperty() [2/3]

void SourceXtractor::SourceWithOnDemandProperties::setProperty ( std::unique_ptr< Property > property,
const PropertyId & property_id )
overrideprotectedvirtual

Implements SourceXtractor::SourceInterface.

Definition at line 61 of file SourceWithOnDemandProperties.cpp.

References m_property_holder, std::move(), and SourceXtractor::PropertyHolder::setProperty().

Here is the call graph for this function:

◆ setProperty() [3/3]

virtual void SourceXtractor::SourceInterface::setProperty ( std::unique_ptr< Property > property,
const PropertyId & property_id )
virtual

Member Data Documentation

◆ m_property_holder

PropertyHolder SourceXtractor::SourceWithOnDemandProperties::m_property_holder
private

Definition at line 77 of file SourceWithOnDemandProperties.h.

Referenced by getProperty(), and setProperty().

◆ m_task_provider

std::shared_ptr<const TaskProvider> SourceXtractor::SourceWithOnDemandProperties::m_task_provider
private

Definition at line 76 of file SourceWithOnDemandProperties.h.

Referenced by getProperty().


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