VariableController2.h
52 lines
| 1.7 KiB
| text/x-c
|
CLexer
r26 | #ifndef VARIABLECONTROLLER2_H | |||
#define VARIABLECONTROLLER2_H | ||||
r0 | #include <memory> | |||
#include <vector> | ||||
r15 | #include <set> | |||
r0 | #include <QHash> | |||
r2 | #include <QObject> | |||
#include <QMutexLocker> | ||||
#include <QUuid> | ||||
r21 | #include <QByteArray> | |||
r2 | #include <QItemSelectionModel> | |||
#include <Common/spimpl.h> | ||||
r0 | #include <Variable/Variable.h> | |||
#include <Data/IDataProvider.h> | ||||
#include "Data/DateTimeRange.h" | ||||
r2 | class VariableController2: public QObject | |||
r0 | { | |||
r2 | class VariableController2Private; | |||
Q_OBJECT | ||||
r0 | spimpl::unique_impl_ptr<VariableController2Private> impl; | |||
public: | ||||
explicit VariableController2(); | ||||
std::shared_ptr<Variable> createVariable(const QString &name, const QVariantHash &metadata, | ||||
r14 | const std::shared_ptr<IDataProvider>& provider, | |||
const DateTimeRange &range); | ||||
r2 | ||||
r20 | std::shared_ptr<Variable> cloneVariable(const std::shared_ptr<Variable>& variable); | |||
r14 | void deleteVariable(const std::shared_ptr<Variable>& variable); | |||
void changeRange(const std::shared_ptr<Variable>& variable, const DateTimeRange& r); | ||||
void asyncChangeRange(const std::shared_ptr<Variable>& variable, const DateTimeRange& r); | ||||
r21 | const std::vector<std::shared_ptr<Variable>> variables(); | |||
r2 | ||||
r17 | bool isReady(const std::shared_ptr<Variable>& variable); | |||
r14 | void synchronize(const std::shared_ptr<Variable>& var, const std::shared_ptr<Variable>& with); | |||
r8 | ||||
r27 | const std::vector<std::shared_ptr<Variable>> variables(const std::vector<QUuid>& ids); | |||
r25 | ||||
const std::shared_ptr<Variable>& operator[] (int index) const; | ||||
std::shared_ptr<Variable> operator[] (int index); | ||||
r8 | ||||
r2 | signals: | |||
r14 | void variableAdded(const std::shared_ptr<Variable>&); | |||
void variableDeleted(const std::shared_ptr<Variable>&); | ||||
r0 | ||||
}; | ||||
r26 | ||||
#endif //VARIABLECONTROLLER2_H | ||||