##// END OF EJS Templates
Merge branch 'feature/AmdaProviderImprovements' into develop
Merge branch 'feature/AmdaProviderImprovements' into develop

File last commit:

r375:49f712bf7e59
r385:0ec770a1fa8f merge
Show More
IDataProvider.h
59 lines | 1.8 KiB | text/x-c | CLexer
Alexandre Leroux
Creates IDataProvider interface
r114 #ifndef SCIQLOP_IDATAPROVIDER_H
#define SCIQLOP_IDATAPROVIDER_H
#include <memory>
Alexandre Leroux
Makes the connection between Data source controller and Variable controller...
r157 #include <QObject>
Alexandre Leroux
Transits tokens in provider requests
r347 #include <QUuid>
Alexandre Leroux
Makes the connection between Data source controller and Variable controller...
r157
Alexandre Leroux
Centralization of qregistermetatype management
r285 #include <Common/MetaTypes.h>
Add merge API and implement it for the DataSeries
r217 #include <Data/SqpDateTime.h>
Alexandre Leroux
Creates IDataProvider interface
r114 class DataProviderParameters;
class IDataSeries;
Add a signal to the IDataProvider API to correspond with the network...
r357 class QNetworkReply;
class QNetworkRequest;
Alexandre Leroux
Creates IDataProvider interface
r114
/**
* @brief The IDataProvider interface aims to declare a data provider.
*
* A data provider is an entity that generates data and returns it according to various parameters
* (time interval, product to retrieve the data, etc.)
*
* @sa IDataSeries
*/
Add merge API and implement it for the DataSeries
r217 class IDataProvider : public QObject {
Q_OBJECT
Alexandre Leroux
Creates IDataProvider interface
r114 public:
virtual ~IDataProvider() noexcept = default;
Add a signal to the IDataProvider API to correspond with the network...
r357 /**
Alexandre Leroux
Updates IDataProvider::requestDataLoading() method's signature...
r375 * @brief requestDataLoading provide datas for the data identified by identifier and parameters
Add a signal to the IDataProvider API to correspond with the network...
r357 */
Alexandre Leroux
Updates IDataProvider::requestDataLoading() method's signature...
r375 virtual void requestDataLoading(QUuid identifier, const DataProviderParameters &parameters) = 0;
Add merge API and implement it for the DataSeries
r217
signals:
Add a signal to the IDataProvider API to correspond with the network...
r357 /**
* @brief dataProvided send dataSeries under dateTime and that corresponds of the data
* identified by identifier
*/
void dataProvided(QUuid identifier, std::shared_ptr<IDataSeries> dateSerie,
Alexandre Leroux
Transits tokens in provider requests
r347 const SqpDateTime &dateTime);
Add a signal to the IDataProvider API to correspond with the network...
r357
/**
* @brief requestConstructed send a request for the data identified by identifier
* @callback is the methode call by the reply of the request when it is finished.
*/
void requestConstructed(const QNetworkRequest &request, QUuid identifier,
std::function<void(QNetworkReply *, QUuid)> callback);
Add merge API and implement it for the DataSeries
r217 };
Alexandre Leroux
Centralization of qregistermetatype management
r285
Alexandre Leroux
Makes the connection between Data source controller and Variable controller...
r157 // Required for using shared_ptr in signals/slots
Alexandre Leroux
Centralization of qregistermetatype management
r285 SCIQLOP_REGISTER_META_TYPE(IDATAPROVIDER_PTR_REGISTRY, std::shared_ptr<IDataProvider>)
Add a signal to the IDataProvider API to correspond with the network...
r357 SCIQLOP_REGISTER_META_TYPE(IDATAPROVIDER_FUNCTION_REGISTRY,
std::function<void(QNetworkReply *, QUuid)>)
Alexandre Leroux
Makes the connection between Data source controller and Variable controller...
r157
Alexandre Leroux
Creates IDataProvider interface
r114 #endif // SCIQLOP_IDATAPROVIDER_H