mirror of
https://github.com/xiaozhou233/JuiceAgent.git
synced 2026-12-05 13:05:53 +08:00
Refactor: rebuild libagent with simplified lifecycle
- Replace eventbus/services with Agent preload/init lifecycle - Move JNI header to shared includes; add jni_common.hpp umbrella header - Reduce ClassFileLoadHook to a stub for later implementation - Add eventpp dependency - Document custom API JAR workflow (WIP)
This commit is contained in:
1 parent
3b180e7199
commit
51bcfbd549
47 files changed
+5583
-1462
No files matched your search
@@ -1,5 +1,4 @@
|
||||
#include <jni_impl.hpp>
|
||||
#include <JuiceAgent.hpp>
|
||||
#include <jni_common.hpp>
|
||||
|
||||
// This function is called by Java to initialize the agent.
|
||||
JNIEXPORT jboolean JNICALL Java_cn_xiaozhou233_juiceagent_api_JuiceAgent_init
|
||||
@@ -37,8 +36,9 @@ JNIEXPORT jboolean JNICALL Java_cn_xiaozhou233_juiceagent_api_JuiceAgent_init
|
||||
}
|
||||
|
||||
// Invoke EntryPoint
|
||||
JuiceAgent::Agent& agent = JuiceAgent::Agent::instance();
|
||||
agent.init(jvm, env, jvmti, runtime_dir);
|
||||
JuiceAgent::Agent& agent = JuiceAgent::Agent::getInstance();
|
||||
agent.preload(jvm, env, jvmti, runtime_dir);
|
||||
agent.init();
|
||||
|
||||
return JNI_TRUE;
|
||||
return JNI_TRUE;
|
||||
}
|
||||
Reference in new issue
Block a user