123456789101112131415161718192021222324252627282930313233343536 |
- #pragma once
- #include "DBStoreBase.h"
- #include "DBTableBase.h"
- #include "DBQueryBase.h"
- #include <wtypes.h>
- namespace OTSSQLITE
- {
- class __declspec(dllexport) CDBBase
- {
- public:
- virtual BOOL Init(const BOOL a_bClean = FALSE) = 0;
- virtual BOOL CreateTable(const BOOL a_bForce = FALSE) = 0;
- virtual BOOL DeleteTable() = 0;
- // Removes all rows.
- virtual BOOL RemoveAllRows() = 0;
- virtual BOOL IsDBExist() = 0;
- virtual CDBStoreBasePtr GetDatastore() = 0;
- virtual CDBTableBasePtr GetTableInfo() = 0;
- virtual CDBQueryBasePtr GetTableQuery(LPCTSTR a_sOrderColumnName = nullptr)=0;
- virtual CDBQueryBasePtr GetCommandStringQuery(LPCTSTR a_commandStr = nullptr) = 0;
- };
- typedef std::shared_ptr<CDBBase> __declspec(dllexport) CDBBasePtr;
- __declspec(dllexport) CDBBasePtr CreateNewSQLiteDB(CDBStoreBasePtr a_datastore, CDBTableBasePtr a_tableInfo);
-
- }
|