mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-13 16:45:20 +02:00
Add dummy and LevelDB database backends
This commit is contained in:
19
src/map.h
19
src/map.h
@@ -33,10 +33,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
||||
#include "modifiedstate.h"
|
||||
#include "util/container.h"
|
||||
#include "nodetimer.h"
|
||||
|
||||
extern "C" {
|
||||
#include "sqlite3.h"
|
||||
}
|
||||
#include "database.h"
|
||||
|
||||
class ClientMap;
|
||||
class MapSector;
|
||||
@@ -425,13 +422,8 @@ public:
|
||||
/*
|
||||
Database functions
|
||||
*/
|
||||
// Create the database structure
|
||||
void createDatabase();
|
||||
// Verify we can read/write to the database
|
||||
void verifyDatabase();
|
||||
// Get an integer suitable for a block
|
||||
static sqlite3_int64 getBlockAsInteger(const v3s16 pos);
|
||||
static v3s16 getIntegerAsBlock(sqlite3_int64 i);
|
||||
|
||||
// Returns true if the database file does not exist
|
||||
bool loadFromFolders();
|
||||
@@ -511,14 +503,7 @@ private:
|
||||
This is reset to false when written on disk.
|
||||
*/
|
||||
bool m_map_metadata_changed;
|
||||
|
||||
/*
|
||||
SQLite database and statements
|
||||
*/
|
||||
sqlite3 *m_database;
|
||||
sqlite3_stmt *m_database_read;
|
||||
sqlite3_stmt *m_database_write;
|
||||
sqlite3_stmt *m_database_list;
|
||||
Database *dbase;
|
||||
};
|
||||
|
||||
#define VMANIP_BLOCK_DATA_INEXIST 1
|
||||
|
Reference in New Issue
Block a user