From a4d2315ee4ca3f6177b4fb2526bed2feff3d89be Mon Sep 17 00:00:00 2001
From: lifan <2308045698@qq.com>
Date: 星期三, 22 十月 2025 16:52:58 +0800
Subject: [PATCH] update
---
jrj/ext-jrj/dllmain.cpp | 52 ++++++++++++++++++++++++++++++++++++++++++++++++----
1 files changed, 48 insertions(+), 4 deletions(-)
diff --git a/jrj/ext-jrj/dllmain.cpp b/jrj/ext-jrj/dllmain.cpp
index daed8c8..a0816b0 100644
--- a/jrj/ext-jrj/dllmain.cpp
+++ b/jrj/ext-jrj/dllmain.cpp
@@ -1,10 +1,22 @@
锘�// dllmain.cpp : 瀹氫箟 DLL 搴旂敤绋嬪簭鐨勫叆鍙g偣銆�
#include "pch.h"
-BOOL APIENTRY DllMain( HMODULE hModule,
- DWORD ul_reason_for_call,
- LPVOID lpReserved
- )
+#include "JObject.hpp"
+#include "JFactoryStringImpl.h"
+//#include "JFileStream.hpp"
+//#include "JDataBlock.hpp"
+//#include "JDataStore.hpp"
+//#include "JDataSet.hpp"
+
+extern "C"
+{
+ bool WINAPI CreateJObjectInstance(LPTSTR pStrObject, JObject*& pJObject);
+}
+
+BOOL APIENTRY DllMain(HMODULE hModule,
+ DWORD ul_reason_for_call,
+ LPVOID lpReserved
+)
{
switch (ul_reason_for_call)
{
@@ -17,3 +29,35 @@
return TRUE;
}
+
+bool WINAPI CreateJObjectInstance(LPTSTR pStrObject, JObject*& pJObject)
+{
+ pJObject = nullptr;
+ if (wcscmp(pStrObject, L"JFactoryString") == 0)
+ {
+ pJObject = new JFactoryStringImpl();
+ return true;
+ }
+ if (wcscmp(pStrObject, L"JString") == 0)
+ {
+ pJObject = new JStringImpl();
+ return true;
+ }
+ /*
+ else if (wcscmp(pStrObject, L"JDataStore")==0)
+ {
+ pJObject = new JDataStore();
+ return true;
+ }
+ else if (wcscmp(pStrObject, L"JDataBlock")==0)
+ {
+ pJObject = new JDataBlock();
+ return true;
+ }
+ else if (wcscmp(pStrObject, L"JDataSet")==0)
+ {
+ pJObject = new JDataSet();
+ return true;
+ }*/
+ return false;
+}
--
Gitblit v1.9.3