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

For each Source it receives, applies PartitionSteps and outputs one or more Sources. More...

#include <Partition.h>

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

Public Member Functions

virtual ~Partition ()=default
 Destructor.
 
 Partition (std::vector< std::shared_ptr< PartitionStep > > steps)
 Constructor - takes a vector of PartitionSteps to be applied in order.
 
void receiveSource (std::unique_ptr< SourceInterface > source) override
 
void receiveProcessSignal (const ProcessSourcesEvent &event) override
 
- Public Member Functions inherited from SourceXtractor::PipelineReceiver< SourceInterface >
virtual ~PipelineReceiver ()=default
 
- Public Member Functions inherited from SourceXtractor::PipelineEmitter< SourceInterface >
 ~PipelineEmitter () override=default
 
void setNextStage (std::shared_ptr< PipelineReceiver< SourceInterface > > next)
 
- Public Member Functions inherited from SourceXtractor::Observable< T >
virtual ~Observable ()=default
 Destructor.
 
virtual void addObserver (std::shared_ptr< Observer< T > > observer)
 Adds an Observer that will be notified when notify Observers is called.
 
virtual void removeObserver (std::shared_ptr< Observer< T > > observer)
 Removes a previously added Observer from the list of Observers to notify.
 

Private Attributes

std::vector< std::shared_ptr< PartitionStep > > m_steps
 

Additional Inherited Members

- Protected Member Functions inherited from SourceXtractor::PipelineEmitter< SourceInterface >
void sendSource (std::unique_ptr< SourceInterface > source) const
 
void sendProcessSignal (const ProcessSourcesEvent &event) const
 
- Protected Member Functions inherited from SourceXtractor::Observable< T >
void notifyObservers (const T &message) const
 

Detailed Description

For each Source it receives, applies PartitionSteps and outputs one or more Sources.

The first PartitionStep is applied to the Source that was received. Each subsequent PartitionStep is applied to the Source(s) produced by the previous step. The Sources resulting from the last step are notified to the Observers one by one.

Definition at line 57 of file Partition.h.

Constructor & Destructor Documentation

◆ ~Partition()

virtual SourceXtractor::Partition::~Partition ( )
virtualdefault

Destructor.

◆ Partition()

SourceXtractor::Partition::Partition ( std::vector< std::shared_ptr< PartitionStep > > steps)
explicit

Constructor - takes a vector of PartitionSteps to be applied in order.

Definition at line 27 of file Partition.cpp.

Member Function Documentation

◆ receiveProcessSignal()

void SourceXtractor::Partition::receiveProcessSignal ( const ProcessSourcesEvent & event)
overridevirtual

Receive a signal to process sources when grouping

Parameters
event

Implements SourceXtractor::PipelineReceiver< SourceInterface >.

Definition at line 57 of file Partition.cpp.

References SourceXtractor::PipelineEmitter< SourceInterface >::sendProcessSignal().

Here is the call graph for this function:

◆ receiveSource()

void SourceXtractor::Partition::receiveSource ( std::unique_ptr< SourceInterface > source)
overridevirtual

Receive a source from the previous stage. The receiver owns the object.

Parameters
source

Implements SourceXtractor::PipelineReceiver< SourceInterface >.

Definition at line 31 of file Partition.cpp.

References m_steps, std::make_move_iterator(), std::move(), and SourceXtractor::PipelineEmitter< SourceInterface >::sendSource().

Here is the call graph for this function:

Member Data Documentation

◆ m_steps

std::vector<std::shared_ptr<PartitionStep> > SourceXtractor::Partition::m_steps
private

Definition at line 72 of file Partition.h.

Referenced by receiveSource().


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