OpenHantek
ExporterRegistry Class Reference

#include <exporterregistry.h>

Inheritance diagram for ExporterRegistry:

Signals

void exporterStatusChanged (const QString &exporterName, const QString &status)
 
void exporterProgressChanged ()
 

Public Member Functions

 ExporterRegistry (const Dso::ControlSpecification *deviceSpecification, DsoSettings *settings, QObject *parent=nullptr)
 
void addRawSamples (PPresult *data)
 
void input (std::shared_ptr< PPresult > data)
 
void registerExporter (ExporterInterface *exporter)
 
void setExporterEnabled (ExporterInterface *exporter, bool enabled)
 
void checkForWaitingExporters ()
 
std::vector< ExporterInterface * >::const_iterator begin ()
 
std::vector< ExporterInterface * >::const_iterator end ()
 

Data Fields

const Dso::ControlSpecificationdeviceSpecification
 Device specifications. More...
 
const DsoSettingssettings
 

Private Member Functions

bool processData (std::shared_ptr< PPresult > &data, ExporterInterface *const &exporter)
 

Private Attributes

std::vector< ExporterInterface * > exporters
 List of all available exporters. More...
 
std::list< ExporterInterface * > enabledExporters
 List of exporters that collect samples at the moment. More...
 
std::set< ExporterInterface * > waitToSaveExporters
 List of exporters that wait to be called back by the user to save their work. More...
 

Constructor & Destructor Documentation

◆ ExporterRegistry()

ExporterRegistry::ExporterRegistry ( const Dso::ControlSpecification deviceSpecification,
DsoSettings settings,
QObject *  parent = nullptr 
)
explicit

Member Function Documentation

◆ addRawSamples()

void ExporterRegistry::addRawSamples ( PPresult data)

◆ begin()

std::vector< ExporterInterface * >::const_iterator ExporterRegistry::begin ( )

◆ checkForWaitingExporters()

void ExporterRegistry::checkForWaitingExporters ( )

◆ end()

std::vector< ExporterInterface * >::const_iterator ExporterRegistry::end ( )

◆ exporterProgressChanged

void ExporterRegistry::exporterProgressChanged ( )
signal

◆ exporterStatusChanged

void ExporterRegistry::exporterStatusChanged ( const QString &  exporterName,
const QString &  status 
)
signal

◆ input()

void ExporterRegistry::input ( std::shared_ptr< PPresult data)

◆ processData()

bool ExporterRegistry::processData ( std::shared_ptr< PPresult > &  data,
ExporterInterface *const &  exporter 
)
private

Process data from addRawSamples() or input() in the given exporter. Add the exporter to waitToSaveExporters if it finishes.

Returns
Return true if the exporter has finished and want to be removed from the enabledExporters list.

◆ registerExporter()

void ExporterRegistry::registerExporter ( ExporterInterface exporter)

◆ setExporterEnabled()

void ExporterRegistry::setExporterEnabled ( ExporterInterface exporter,
bool  enabled 
)

Field Documentation

◆ deviceSpecification

const Dso::ControlSpecification* ExporterRegistry::deviceSpecification

Device specifications.

◆ enabledExporters

std::list<ExporterInterface *> ExporterRegistry::enabledExporters
private

List of exporters that collect samples at the moment.

◆ exporters

std::vector<ExporterInterface *> ExporterRegistry::exporters
private

List of all available exporters.

◆ settings

const DsoSettings* ExporterRegistry::settings

◆ waitToSaveExporters

std::set<ExporterInterface *> ExporterRegistry::waitToSaveExporters
private

List of exporters that wait to be called back by the user to save their work.


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