Added store_mysql_fake persistence solution, to compile a ROC CMS system with mysql interface, but no real mysql driver.

This is mainly during dev using sqlite, to include the mysql interfaces without depending on related C .lib files that are not always compiled.
This commit is contained in:
Jocelyn Fiat
2017-09-06 10:26:47 +02:00
parent b6a5b4bc7f
commit 2fcbcf1938
4 changed files with 87 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
note
description: "Summary description for {CMS_STORAGE_STORE_MYSQL}."
date: "$Date$"
revision: "$Revision$"
class
CMS_STORAGE_STORE_MYSQL
inherit
CMS_STORAGE_NULL
create
make
feature
make
do
default_create
end
end -- class CMS_STORAGE_STORE_MYSQL

View File

@@ -0,0 +1,36 @@
note
description: "[
Interface responsible to instantiate CMS_STORAGE_STORE_MYSQL object.
]"
author: "$Author$"
date: "$Date$"
revision: "$Revision$"
class
CMS_STORAGE_STORE_MYSQL_BUILDER
inherit
CMS_STORAGE_NULL_BUILDER
redefine
storage
end
create
make
feature {NONE}
make
do
end
feature
storage (a_setup: CMS_SETUP; a_error_handler: ERROR_HANDLER): detachable CMS_STORAGE_NULL
-- CMS Storage object based on CMS setup `a_setup`.
do
a_error_handler.add_custom_error (0, "Could not connect to the MySQL storage", Void)
end
end -- class CMS_STORAGE_STORE_MYSQL_BUILDER