##// END OF EJS Templates
Fix the problem of calling the zoom at wheel event on the color scale
Fix the problem of calling the zoom at wheel event on the color scale

File last commit:

r1362:c5e93e891fc6
r1390:ed0f1486704f
Show More
CatalogueController.h
93 lines | 3.2 KiB | text/x-c | CLexer
/ core / include / Catalogue / CatalogueController.h
correction of merge
r1097 #ifndef SCIQLOP_CATALOGUECONTROLLER_H
#define SCIQLOP_CATALOGUECONTROLLER_H
#include "CoreGlobal.h"
#include <Data/SqpRange.h>
#include <QLoggingCategory>
#include <QObject>
#include <QUuid>
#include <Common/spimpl.h>
Add retrieve events impl
r1158 #include <memory>
class DBCatalogue;
class DBEvent;
Add missing methods
r1282 class DBEventProduct;
Add retrieve events impl
r1158
correction of merge
r1097 Q_DECLARE_LOGGING_CATEGORY(LOG_CatalogueController)
class DataSourceItem;
class Variable;
/**
Add retrieve events impl
r1158 * @brief The CatalogueController class aims to handle catalogues and event using the CatalogueAPI
* library.
correction of merge
r1097 */
class SCIQLOP_CORE_EXPORT CatalogueController : public QObject {
Q_OBJECT
public:
explicit CatalogueController(QObject *parent = 0);
virtual ~CatalogueController();
Add retrieve events impl
r1158 // DB
Add Catalogue methods
r1191 QStringList getRepositories() const;
Add retrieve events impl
r1158 void addDB(const QString &dbPath);
void saveDB(const QString &destinationPath, const QString &repository);
// Event
Add Catalogue methods
r1191 /// retrieveEvents with empty repository retrieve them from the default repository
Add retrieve events impl
r1158 std::list<std::shared_ptr<DBEvent> > retrieveEvents(const QString &repository) const;
std::list<std::shared_ptr<DBEvent> > retrieveAllEvents() const;
Add fix for default repository init
r1310
Add Catalogue methods
r1191 void addEvent(std::shared_ptr<DBEvent> event);
void updateEvent(std::shared_ptr<DBEvent> event);
Add missing methods
r1282 void updateEventProduct(std::shared_ptr<DBEventProduct> eventProduct);
Add Catalogue methods
r1191 void removeEvent(std::shared_ptr<DBEvent> event);
CatalogueController: add few basic methods + commit the one not yet implemented
r1161 // void trashEvent(std::shared_ptr<DBEvent> event);
Add discard method for event
r1298 // void restore(std::shared_ptr<DBEvent> event);
Add Catalogue methods
r1191 void saveEvent(std::shared_ptr<DBEvent> event);
Discard an added event remove it now.
r1314 void discardEvent(std::shared_ptr<DBEvent> event, bool &removed);
store events with changes in the catalogue controller
r1292 bool eventHasChanges(std::shared_ptr<DBEvent> event) const;
correction of merge
r1097
Add retrieve events impl
r1158 // Catalogue
Add fix for default repository init
r1310 std::list<std::shared_ptr<DBEvent> >
retrieveEventsFromCatalogue(std::shared_ptr<DBCatalogue> catalogue) const;
Add fix for default repository init
r1353
Add Catalogue methods
r1191 /// retrieveEvents with empty repository retrieve them from the default repository
Adaptation to last version of catalogue controller
r1196 std::list<std::shared_ptr<DBCatalogue> > retrieveCatalogues(const QString &repository
= QString()) const;
mperrinel
Add Catalogue methods
r1352 void addCatalogue(std::shared_ptr<DBCatalogue> catalogue);
Add Catalogue methods
r1191 void updateCatalogue(std::shared_ptr<DBCatalogue> catalogue);
void removeCatalogue(std::shared_ptr<DBCatalogue> catalogue);
void saveCatalogue(std::shared_ptr<DBCatalogue> catalogue);
Add catalogue handling
r1356 void discardCatalogue(std::shared_ptr<DBCatalogue> catalogue, bool &removed);
Add Catalogue methods
r1191
void saveAll();
Check unsaved data on close
r1294 bool hasChanges() const;
correction of merge
r1097
Drop of events on a catalogue
r1285 /// Returns the MIME data associated to a list of variables
QByteArray mimeDataForEvents(const QVector<std::shared_ptr<DBEvent> > &events) const;
/// Returns the list of variables contained in a MIME data
QVector<std::shared_ptr<DBEvent> > eventsForMimeData(const QByteArray &mimeData) const;
Move event in catalogue with Drag&Drop
r1362 /// Returns the MIME data associated to a list of variables
QByteArray
mimeDataForCatalogues(const QVector<std::shared_ptr<DBCatalogue> > &catalogues) const;
/// Returns the list of variables contained in a MIME data
QVector<std::shared_ptr<DBCatalogue> > cataloguesForMimeData(const QByteArray &mimeData) const;
correction of merge
r1097 public slots:
/// Manage init/end of the controller
void initialize();
private:
class CatalogueControllerPrivate;
spimpl::unique_impl_ptr<CatalogueControllerPrivate> impl;
};
#endif // SCIQLOP_CATALOGUECONTROLLER_H