1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
| #ifndef DATABASE_H
| #define DATABASE_H
|
| #include <string>
| #include <vector>
|
| #ifdef BUILDING_DLL
| #define DLL_API __declspec(dllexport)
| #else
| #define DLL_API __declspec(dllimport)
| #endif
|
| namespace BL {
| class DLL_API Database {
| public:
| virtual ~Database() {}
|
| virtual bool connect(const std::string& connectionString, bool createIfNotExists = false) = 0;
| virtual void disconnect() = 0;
| virtual bool executeQuery(const std::string& query) = 0;
| virtual std::vector<std::vector<std::string>> fetchResults(const std::string& query) = 0;
| };
| }
|
| #endif // DATABASE_H
|
|