36 lines
483 B
C++
36 lines
483 B
C++
#pragma once
|
|
|
|
#include "ehs/Array.h"
|
|
#include "DbTable.h"
|
|
|
|
namespace ehs
|
|
{
|
|
class Database
|
|
{
|
|
private:
|
|
UInt_64 hashId;
|
|
Str_8 id;
|
|
Array<DbTable> tables;
|
|
|
|
public:
|
|
Database();
|
|
|
|
Database(const Str_8& filePath);
|
|
|
|
UInt_64 GetHashId() const;
|
|
|
|
Str_8 GetId() const;
|
|
|
|
bool HasTable(UInt_64 hashId) const;
|
|
|
|
bool HasTable(Str_8& id) const;
|
|
|
|
bool CreateTable(Str_8 id);
|
|
|
|
DbTable* GetTable(UInt_64 hashId) const;
|
|
|
|
DbTable* GetTable(Str_8& id) const;
|
|
|
|
void Save();
|
|
};
|
|
} |