From f4a11ef825cf64c085a2d3412df7623363a2d2a7 Mon Sep 17 00:00:00 2001 From: Sandu Liviu Catalin Date: Sat, 27 Feb 2016 11:57:10 +0200 Subject: [PATCH] Separated major non mandatory libraries into their onwn modules. Consolidated and simplified the module API system. Various other fixes and improvements. --- cbp/LibIRC.cbp | 177 -- cbp/ModINI.cbp | 395 ++++ cbp/ModIRC.cbp | 398 ++++ cbp/ModSample.cbp | 383 ++++ cbp/ModXML.cbp | 391 ++++ cbp/Module.cbp | 232 +- cbp/SQLite.cbp | 176 -- cbp/Sample.cbp | 199 -- cbp/Sandbox.cbp | 1 - cbp/default.workspace | 7 +- external/LibIRC/portable.c | 18 +- external/LibIRC/sockets.c | 20 +- include/sqrat.h | 2 +- include/sqrat/sqratAllocator.h | 2 +- include/sqrat/sqratArray.h | 2 +- include/sqrat/sqratClass.h | 2 +- include/sqrat/sqratClassType.h | 2 +- include/sqrat/sqratConst.h | 2 +- include/sqrat/sqratFunction.h | 2 +- include/sqrat/sqratGlobalMethods.h | 2 +- include/sqrat/sqratMemberMethods.h | 2 +- include/sqrat/sqratObject.h | 2 +- include/sqrat/sqratOverloadMethods.h | 2 +- include/sqrat/sqratScript.h | 2 +- include/sqrat/sqratTable.h | 2 +- include/sqrat/sqratTypes.h | 2 +- include/sqrat/sqratUtil.h | 2 +- modules/ini/Common.cpp | 35 + modules/ini/Common.hpp | 396 ++++ modules/ini/Document.cpp | 227 ++ modules/ini/Document.hpp | 408 ++++ modules/ini/Entries.cpp | 85 + modules/ini/Entries.hpp | 220 ++ modules/ini/Module.cpp | 414 ++++ modules/ini/Module.hpp | 41 + modules/irc/Common.cpp | 33 + modules/irc/Common.hpp | 40 + modules/irc/Module.cpp | 620 +++++ modules/irc/Module.hpp | 41 + .../IRC.cpp => modules/irc/Session.cpp | 581 ++--- .../IRC.hpp => modules/irc/Session.hpp | 126 +- modules/sample/Common.cpp | 24 + modules/sample/Common.hpp | 66 + modules/sample/Module.cpp | 310 +++ modules/sample/Module.hpp | 41 + modules/xml/Attribute.cpp | 193 ++ modules/xml/Attribute.hpp | 427 ++++ modules/xml/Common.cpp | 25 + modules/xml/Common.hpp | 392 ++++ modules/xml/Document.cpp | 41 + modules/xml/Document.hpp | 221 ++ modules/xml/Module.cpp | 592 +++++ {sample => modules/xml}/Module.hpp | 24 +- modules/xml/Node.cpp | 118 + modules/xml/Node.hpp | 580 +++++ modules/xml/Text.cpp | 198 ++ modules/xml/Text.hpp | 365 +++ sample/Module.cpp | 229 -- shared/ModBase.hpp | 1161 ++++++++++ shared/{sq_api.h => SqAPI.h} | 0 shared/{sq_mod.c => SqMod.c} | 4 +- shared/{sq_mod.cpp => SqMod.cpp} | 4 +- shared/SqMod.h | 136 ++ shared/SqMod.inl | 587 +++++ shared/sq_mod.h | 579 ----- shared/sq_mod.inl | 1968 ---------------- source/Base/Shared.hpp | 15 + source/Core.cpp | 25 +- source/Exports.cpp | 210 +- source/Library/INI.cpp | 533 ----- source/Library/INI.hpp | 736 ------ source/Library/Numeric.cpp | 18 +- source/Library/Numeric.hpp | 16 + source/Library/Random.cpp | 4 +- source/Library/Time.hpp | 8 + source/Library/Utils.hpp | 41 + source/Library/XML.cpp | 325 --- source/Library/XML.hpp | 2037 ----------------- source/Logger.cpp | 86 + source/Main.cpp | 46 +- source/Misc/Functions.cpp | 2 +- source/Register.cpp | 8 - 82 files changed, 10509 insertions(+), 7580 deletions(-) delete mode 100644 cbp/LibIRC.cbp create mode 100644 cbp/ModINI.cbp create mode 100644 cbp/ModIRC.cbp create mode 100644 cbp/ModSample.cbp create mode 100644 cbp/ModXML.cbp delete mode 100644 cbp/SQLite.cbp delete mode 100644 cbp/Sample.cbp create mode 100644 modules/ini/Common.cpp create mode 100644 modules/ini/Common.hpp create mode 100644 modules/ini/Document.cpp create mode 100644 modules/ini/Document.hpp create mode 100644 modules/ini/Entries.cpp create mode 100644 modules/ini/Entries.hpp create mode 100644 modules/ini/Module.cpp create mode 100644 modules/ini/Module.hpp create mode 100644 modules/irc/Common.cpp create mode 100644 modules/irc/Common.hpp create mode 100644 modules/irc/Module.cpp create mode 100644 modules/irc/Module.hpp rename source/Library/IRC.cpp => modules/irc/Session.cpp (58%) rename source/Library/IRC.hpp => modules/irc/Session.hpp (95%) create mode 100644 modules/sample/Common.cpp create mode 100644 modules/sample/Common.hpp create mode 100644 modules/sample/Module.cpp create mode 100644 modules/sample/Module.hpp create mode 100644 modules/xml/Attribute.cpp create mode 100644 modules/xml/Attribute.hpp create mode 100644 modules/xml/Common.cpp create mode 100644 modules/xml/Common.hpp create mode 100644 modules/xml/Document.cpp create mode 100644 modules/xml/Document.hpp create mode 100644 modules/xml/Module.cpp rename {sample => modules/xml}/Module.hpp (61%) create mode 100644 modules/xml/Node.cpp create mode 100644 modules/xml/Node.hpp create mode 100644 modules/xml/Text.cpp create mode 100644 modules/xml/Text.hpp delete mode 100644 sample/Module.cpp create mode 100644 shared/ModBase.hpp rename shared/{sq_api.h => SqAPI.h} (100%) rename shared/{sq_mod.c => SqMod.c} (69%) rename shared/{sq_mod.cpp => SqMod.cpp} (69%) create mode 100644 shared/SqMod.h create mode 100644 shared/SqMod.inl delete mode 100644 shared/sq_mod.h delete mode 100644 shared/sq_mod.inl delete mode 100644 source/Library/INI.cpp delete mode 100644 source/Library/INI.hpp delete mode 100644 source/Library/XML.cpp delete mode 100644 source/Library/XML.hpp diff --git a/cbp/LibIRC.cbp b/cbp/LibIRC.cbp deleted file mode 100644 index a323c0d6..00000000 --- a/cbp/LibIRC.cbp +++ /dev/null @@ -1,177 +0,0 @@ - - - - - - diff --git a/cbp/ModINI.cbp b/cbp/ModINI.cbp new file mode 100644 index 00000000..15768123 --- /dev/null +++ b/cbp/ModINI.cbp @@ -0,0 +1,395 @@ + + + + + + diff --git a/cbp/ModIRC.cbp b/cbp/ModIRC.cbp new file mode 100644 index 00000000..dc466e07 --- /dev/null +++ b/cbp/ModIRC.cbp @@ -0,0 +1,398 @@ + + + + + + diff --git a/cbp/ModSample.cbp b/cbp/ModSample.cbp new file mode 100644 index 00000000..4b6bd938 --- /dev/null +++ b/cbp/ModSample.cbp @@ -0,0 +1,383 @@ + + + + + + diff --git a/cbp/ModXML.cbp b/cbp/ModXML.cbp new file mode 100644 index 00000000..68747bca --- /dev/null +++ b/cbp/ModXML.cbp @@ -0,0 +1,391 @@ + + + + + + diff --git a/cbp/Module.cbp b/cbp/Module.cbp index 54865251..745f74ec 100644 --- a/cbp/Module.cbp +++ b/cbp/Module.cbp @@ -7,7 +7,7 @@