i did nothing
This commit is contained in:
parent
846bc6ef2f
commit
6491e7170b
2 changed files with 10 additions and 7 deletions
|
@ -1,7 +1,8 @@
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
const char* _mem_db_sql =
|
const char* _mem_db_sql =
|
||||||
"CREATE TABLE ";
|
"CREATE TABLE SERVER_LIST ( "
|
||||||
|
");";
|
||||||
|
|
||||||
const std::vector<const char*> _hard_db_sql = {
|
const std::vector<const char*> _hard_db_sql = {
|
||||||
/** START MIGRATION 0 **/
|
/** START MIGRATION 0 **/
|
||||||
|
|
|
@ -3,6 +3,7 @@
|
||||||
|
|
||||||
#include "sqlite/sqlite3.h"
|
#include "sqlite/sqlite3.h"
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
#include <string>
|
||||||
|
|
||||||
namespace sosc {
|
namespace sosc {
|
||||||
namespace db {
|
namespace db {
|
||||||
|
@ -15,14 +16,15 @@ private:
|
||||||
|
|
||||||
class Query {
|
class Query {
|
||||||
public:
|
public:
|
||||||
template<typename T>
|
Query();
|
||||||
static T ScalarOnce();
|
Query(const std::string& query);
|
||||||
static void NonQueryOnce();
|
void SetQuery(const std::string& query);
|
||||||
static ResultSet Once();
|
|
||||||
|
|
||||||
|
|
||||||
|
void Reset();
|
||||||
|
void Close();
|
||||||
private:
|
private:
|
||||||
|
std::string query;
|
||||||
|
bool open;
|
||||||
};
|
};
|
||||||
|
|
||||||
// THE FOLLOWING ARE NOT THREAD SAFE !!
|
// THE FOLLOWING ARE NOT THREAD SAFE !!
|
||||||
|
|
Loading…
Reference in a new issue