Accelerated Computation Engine
Public Member Functions | Protected Slots | Protected Member Functions | List of all members
Ace::Analytic::Merge Class Reference

#include <ace_analytic_merge.h>

Inheritance diagram for Ace::Analytic::Merge:
Ace::Analytic::AbstractManager Ace::Analytic::AbstractInput

Public Member Functions

virtual bool isFinished () const override final
 
 Merge (quint16 type, int size)
 
- Public Member Functions inherited from Ace::Analytic::AbstractManager
quint16 analyticType () const
 
int size () const
 
EAbstractAnalytic::Input::Type type (int index) const
 
QVariant data (int index, EAbstractAnalytic::Input::Role role) const
 
QList< QString > commandLineArguments () const
 
void set (int index, const QVariant &value)
 
- Public Member Functions inherited from Ace::Analytic::AbstractInput
virtual void saveResult (std::unique_ptr< EAbstractAnalytic::Block > &&result)
 
 AbstractInput ()=default
 
 ~AbstractInput ()
 

Protected Slots

virtual void start () override final
 
void process ()
 
- Protected Slots inherited from Ace::Analytic::AbstractManager
virtual void start ()
 

Protected Member Functions

virtual int index () const override final
 
virtual void writeResult (std::unique_ptr< EAbstractAnalytic::Block > &&result) override final
 
- Protected Member Functions inherited from Ace::Analytic::AbstractManager
virtual QFile * addOutputFile (const QString &path)
 
virtual Ace::DataObjectaddOutputData (const QString &path, quint16 type, const EMetadata &system)
 
 AbstractManager (quint16 type)
 
std::unique_ptr< EAbstractAnalytic::BlockmakeWork (int index)
 
void writeResult (std::unique_ptr< EAbstractAnalytic::Block > &&result, int expectedIndex)
 
EAbstractAnalyticanalytic ()
 
const EAbstractAnalyticanalytic () const
 

Additional Inherited Members

- Public Slots inherited from Ace::Analytic::AbstractManager
void initialize ()
 
void terminationRequested ()
 
void finish ()
 
- Signals inherited from Ace::Analytic::AbstractManager
void progressed (int percentComplete)
 
void done ()
 
void finished ()
 
- Static Public Member Functions inherited from Ace::Analytic::AbstractManager
static std::unique_ptr< Ace::Analytic::AbstractManagermakeManager (quint16 type, int index, int size)
 

Detailed Description

This is the merge manager. This manager is used to take all the chunk files produced by all the chunk run processes and merge them together finishing the execution of the underlying analytic by having it process all result blocks stored in the temporary binary chunk files.

Constructor & Destructor Documentation

◆ Merge()

Merge::Merge ( quint16  type,
int  size 
)
explicit

Constructs a new merge manager with the given analytic type and the given chunk size.

Parameters
typeThe analytic type that is used by this manager.
sizeThe chunk size of the chunk runs this manager will merge to finish the analytic.

Member Function Documentation

◆ index()

int Merge::index ( ) const
finaloverrideprotectedvirtual

Implements the interface that returns the next expected result block index to maintain order of result blocks.

Returns
The next expected result block index to maintain order.

Reimplemented from Ace::Analytic::AbstractInput.

◆ isFinished()

bool Merge::isFinished ( ) const
finaloverridevirtual

Implements the interface that tests if this abstract input is finished and received all result blocks for its analytic.

Returns
True if this abstract input is finished or false otherwise.

Implements Ace::Analytic::AbstractInput.

◆ process

void Merge::process ( )
protectedslot

Called to process all temporary chunk files, merging them all together by sorting all result blocks and processing them with this manager's analytic.

◆ start

void Merge::start ( )
finaloverrideprotectedvirtualslot

Implements the interface that is called once to begin the analytic run for this manager after all argument input has been set.

◆ writeResult()

void Merge::writeResult ( std::unique_ptr< EAbstractAnalytic::Block > &&  result)
finaloverrideprotectedvirtual

Implements the interface that is called to save the given result block to the underlying analytic and it can be assumed that the index order is maintained from least to greatest.

Parameters
resultThe result block that is processed by this manager's abstract analytic.

Reimplemented from Ace::Analytic::AbstractInput.


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