qt5
Last change
on this file since 05afe5f was
05afe5f,
checked in by pavelpa <pavelpa@…>, 12 years ago
|
implemented 'tab container' widget, which groups daynavigator with treeview
- moved functionality from mainwindow to tabcontainer
- TODO: 'search' tab not done yet
|
-
Property mode set to
100644
|
File size:
967 bytes
|
Rev | Line | |
---|
[72f6fe4] | 1 | #ifndef SQLENGINE_H |
---|
| 2 | #define SQLENGINE_H |
---|
| 3 | |
---|
| 4 | #include <QObject> |
---|
| 5 | #include <QHash> |
---|
| 6 | |
---|
| 7 | class QSqlDatabase; |
---|
| 8 | |
---|
| 9 | class SqlEngine : public QObject |
---|
| 10 | { |
---|
| 11 | Q_OBJECT |
---|
| 12 | public: |
---|
| 13 | SqlEngine(QObject *aParent = NULL); |
---|
| 14 | ~SqlEngine(); |
---|
[05afe5f] | 15 | static void initialize(); |
---|
[72f6fe4] | 16 | void addConferenceToDB(QHash<QString,QString> &aConference); |
---|
| 17 | void addEventToDB(QHash<QString,QString> &aEvent); |
---|
| 18 | void addPersonToDB(QHash<QString,QString> &aPerson); |
---|
| 19 | void addLinkToDB(QHash<QString,QString> &aLink); |
---|
| 20 | void addRoomToDB(QHash<QString,QString> &aRoom); |
---|
[990afd5] | 21 | |
---|
| 22 | // search Events for .... |
---|
[c7b58d4] | 23 | int searchEvent(int conferenceId, const QHash<QString,QString> &columns, const QString &keyword); |
---|
[72f6fe4] | 24 | private: |
---|
[05afe5f] | 25 | static QString login(const QString &aDatabaseType, const QString &aDatabaseName); |
---|
| 26 | static bool createTables(QSqlDatabase &aDatabase); |
---|
[e662750] | 27 | bool execQuery(QSqlDatabase &aDatabase, const QString &aQuery); |
---|
[72f6fe4] | 28 | }; |
---|
| 29 | |
---|
| 30 | #endif /* SQLENGINE_H */ |
---|
| 31 | |
---|
Note: See
TracBrowser
for help on using the repository browser.