mirror of
https://github.com/Relintai/rcpp_framework.git
synced 2024-11-14 04:57:21 +01:00
Moved core/databases to just datatbases. Also fox database module detection login.
This commit is contained in:
parent
309208d359
commit
81780683a4
@ -207,7 +207,7 @@ database_list = []
|
||||
if env_base["databases"]:
|
||||
env_base.Append(CPPDEFINES=["DATABASES_ENABLED"])
|
||||
|
||||
for x in sorted(glob.glob("database/*")):
|
||||
for x in sorted(glob.glob("database_modules/*")):
|
||||
if not os.path.isdir(x) or not os.path.exists(x + "/detect.py"):
|
||||
continue
|
||||
tmppath = "./" + x
|
||||
@ -216,8 +216,8 @@ if env_base["databases"]:
|
||||
import detect
|
||||
|
||||
if detect.is_active() and detect.can_build():
|
||||
x = x.replace("database/", "") # rest of world
|
||||
x = x.replace("database\\", "") # win32
|
||||
x = x.replace("database_modules/", "") # rest of world
|
||||
x = x.replace("database_modules\\", "") # win32
|
||||
database_list += [x]
|
||||
|
||||
sys.path.remove(tmppath)
|
||||
@ -278,7 +278,7 @@ SConscript("web/SCsub")
|
||||
SConscript("platform/SCsub")
|
||||
|
||||
if env_base["databases"]:
|
||||
#add db folder
|
||||
SConscript("database/SCsub")
|
||||
|
||||
for d in database_list:
|
||||
tmppath = "./database_modules/" + d
|
||||
|
@ -1,6 +1,6 @@
|
||||
#include "object.h"
|
||||
|
||||
#include "core/database/database.h"
|
||||
#include "database/database.h"
|
||||
|
||||
Object::Object() {
|
||||
db = nullptr;
|
||||
|
@ -1,10 +1,10 @@
|
||||
#include "db_settings.h"
|
||||
|
||||
#include "core/database/database.h"
|
||||
#include "core/database/database_manager.h"
|
||||
#include "core/database/query_builder.h"
|
||||
#include "core/database/query_result.h"
|
||||
#include "core/database/table_builder.h"
|
||||
#include "database/database.h"
|
||||
#include "database/database_manager.h"
|
||||
#include "database/query_builder.h"
|
||||
#include "database/query_result.h"
|
||||
#include "database/table_builder.h"
|
||||
|
||||
void DBSettings::set_value(const String &key, const Variant &value) {
|
||||
const Variant &v = _data[key];
|
||||
|
11
database/SCsub
Normal file
11
database/SCsub
Normal file
@ -0,0 +1,11 @@
|
||||
#!/usr/bin/env python
|
||||
|
||||
Import("env")
|
||||
|
||||
env.core_sources = []
|
||||
|
||||
env.add_source_files(env.core_sources, "*.cpp")
|
||||
|
||||
# Build it all as a library
|
||||
lib = env.add_library("database", env.core_sources)
|
||||
env.Prepend(LIBS=[lib])
|
@ -2,7 +2,7 @@
|
||||
|
||||
#include <cstdio>
|
||||
|
||||
#include "core/database/database_manager.h"
|
||||
#include "database/database_manager.h"
|
||||
|
||||
#include "mysql_query_builder.h"
|
||||
#include "mysql_query_result.h"
|
||||
|
@ -3,7 +3,7 @@
|
||||
|
||||
#include "core/string.h"
|
||||
|
||||
#include "core/database/database.h"
|
||||
#include "database/database.h"
|
||||
|
||||
#include <memory>
|
||||
|
||||
|
@ -4,7 +4,7 @@
|
||||
#include <memory>
|
||||
#include "core/string.h"
|
||||
|
||||
#include "core/database/query_builder.h"
|
||||
#include "database/query_builder.h"
|
||||
|
||||
class MysqlDatabase;
|
||||
class MysqlQueryResult;
|
||||
|
@ -1,7 +1,7 @@
|
||||
#ifndef MYSQL_QUERY_RESULT_H
|
||||
#define MYSQL_QUERY_RESULT_H
|
||||
|
||||
#include "core/database/query_result.h"
|
||||
#include "database/query_result.h"
|
||||
|
||||
#include <mysql.h>
|
||||
|
||||
|
@ -3,7 +3,7 @@
|
||||
|
||||
#include "core/string.h"
|
||||
|
||||
#include "core/database/table_builder.h"
|
||||
#include "database/table_builder.h"
|
||||
|
||||
class MysqlTableBuilder : public TableBuilder {
|
||||
RCPP_OBJECT(MysqlTableBuilder, TableBuilder);
|
||||
|
@ -1,6 +1,6 @@
|
||||
#include "pgsql_database.h"
|
||||
|
||||
#include "core/database/database_manager.h"
|
||||
#include "database/database_manager.h"
|
||||
|
||||
Database *PGSQLDatabase::_creation_func() {
|
||||
return new PGSQLDatabase();
|
||||
|
@ -1,7 +1,7 @@
|
||||
#ifndef PGSQL_CONNECTION
|
||||
#define PGSQL_CONNECTION
|
||||
|
||||
#include "core/database/database.h"
|
||||
#include "database/database.h"
|
||||
|
||||
//Brynet has it aswell, and because of using namespace it is defined here aswell
|
||||
//later this will be fixed better
|
||||
|
@ -1,6 +1,6 @@
|
||||
#include "sqlite3_database.h"
|
||||
|
||||
#include "core/database/database_manager.h"
|
||||
#include "database/database_manager.h"
|
||||
|
||||
#include "sqlite3_query_builder.h"
|
||||
#include "sqlite3_query_result.h"
|
||||
|
@ -1,7 +1,7 @@
|
||||
#ifndef SQLITE3_CONNECTION
|
||||
#define SQLITE3_CONNECTION
|
||||
|
||||
#include "core/database/database.h"
|
||||
#include "database/database.h"
|
||||
|
||||
//Brynet has it aswell, and because of using namespace it is defined here aswell
|
||||
//later this will be fixed better
|
||||
|
@ -4,7 +4,7 @@
|
||||
#include <memory>
|
||||
#include <string>
|
||||
|
||||
#include "core/database/query_builder.h"
|
||||
#include "database/query_builder.h"
|
||||
|
||||
class SQLite3Database;
|
||||
|
||||
|
@ -4,7 +4,7 @@
|
||||
#include "core/string.h"
|
||||
#include <vector>
|
||||
|
||||
#include "core/database/query_result.h"
|
||||
#include "database/query_result.h"
|
||||
|
||||
#include "./sqlite/sqlite3.h"
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
#include "sqlite3_table_builder.h"
|
||||
|
||||
#include "core/database/query_result.h"
|
||||
#include "database/query_result.h"
|
||||
|
||||
#include "sqlite3_database.h"
|
||||
|
||||
|
@ -3,7 +3,7 @@
|
||||
|
||||
#include "core/string.h"
|
||||
|
||||
#include "core/database/table_builder.h"
|
||||
#include "database/table_builder.h"
|
||||
|
||||
class SQLite3Database;
|
||||
|
||||
|
@ -4,10 +4,10 @@
|
||||
#include <stdlib.h>
|
||||
#include <time.h>
|
||||
|
||||
#include "core/database/database_manager.h"
|
||||
#include "core/database/query_builder.h"
|
||||
#include "core/database/query_result.h"
|
||||
#include "core/database/table_builder.h"
|
||||
#include "database/database_manager.h"
|
||||
#include "database/query_builder.h"
|
||||
#include "database/query_result.h"
|
||||
#include "database/table_builder.h"
|
||||
|
||||
#include "core/hash/sha256.h"
|
||||
|
||||
|
@ -8,11 +8,11 @@
|
||||
#include "core/settings/settings.h"
|
||||
|
||||
#ifdef DATABASES_ENABLED
|
||||
#include "core/database/database.h"
|
||||
#include "core/database/database_manager.h"
|
||||
#include "core/database/query_builder.h"
|
||||
#include "core/database/query_result.h"
|
||||
#include "core/database/table_builder.h"
|
||||
#include "database/database.h"
|
||||
#include "database/database_manager.h"
|
||||
#include "database/query_builder.h"
|
||||
#include "database/query_result.h"
|
||||
#include "database/table_builder.h"
|
||||
#endif
|
||||
|
||||
String WebNode::get_uri_segment() {
|
||||
|
@ -4,7 +4,7 @@
|
||||
|
||||
#include <iostream>
|
||||
#include "core/file_cache.h"
|
||||
#include "core/database/database_manager.h"
|
||||
#include "database/database_manager.h"
|
||||
#include "web/html/html_builder.h"
|
||||
|
||||
void StaticFolderPage::handle_request_main(Request *request) {
|
||||
|
@ -1,10 +1,10 @@
|
||||
#include "message_page.h"
|
||||
|
||||
#include "core/database/database.h"
|
||||
#include "database/database.h"
|
||||
|
||||
#include "core/database/query_builder.h"
|
||||
#include "core/database/table_builder.h"
|
||||
#include "core/database/query_result.h"
|
||||
#include "database/query_builder.h"
|
||||
#include "database/table_builder.h"
|
||||
#include "database/query_result.h"
|
||||
|
||||
void MessagePage::handle_request_main(Request *request) {
|
||||
Ref<QueryBuilder> b = db->get_query_builder();
|
||||
|
@ -11,11 +11,11 @@
|
||||
#include "rbac_default_permissions.h"
|
||||
#include "web_modules/users/user.h"
|
||||
|
||||
#include "core/database/database.h"
|
||||
#include "core/database/database_manager.h"
|
||||
#include "core/database/query_builder.h"
|
||||
#include "core/database/query_result.h"
|
||||
#include "core/database/table_builder.h"
|
||||
#include "database/database.h"
|
||||
#include "database/database_manager.h"
|
||||
#include "database/query_builder.h"
|
||||
#include "database/query_result.h"
|
||||
#include "database/table_builder.h"
|
||||
|
||||
void RBACController::handle_request_main(Request *request) {
|
||||
}
|
||||
|
@ -8,10 +8,10 @@
|
||||
#include <tinydir/tinydir.h>
|
||||
#include <cstdio>
|
||||
|
||||
#include "core/database/database_manager.h"
|
||||
#include "core/database/query_builder.h"
|
||||
#include "core/database/query_result.h"
|
||||
#include "core/database/table_builder.h"
|
||||
#include "database/database_manager.h"
|
||||
#include "database/query_builder.h"
|
||||
#include "database/query_result.h"
|
||||
#include "database/table_builder.h"
|
||||
|
||||
#include "web/html/form_validator.h"
|
||||
#include "web/html/html_builder.h"
|
||||
|
@ -7,11 +7,11 @@
|
||||
#include "web/http/request.h"
|
||||
#include "web/http/session_manager.h"
|
||||
|
||||
#include "core/database/database.h"
|
||||
#include "core/database/database_manager.h"
|
||||
#include "core/database/query_builder.h"
|
||||
#include "core/database/query_result.h"
|
||||
#include "core/database/table_builder.h"
|
||||
#include "database/database.h"
|
||||
#include "database/database_manager.h"
|
||||
#include "database/query_builder.h"
|
||||
#include "database/query_result.h"
|
||||
#include "database/table_builder.h"
|
||||
|
||||
#include "core/hash/sha256.h"
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user