Added ModuleApplication function and merge findClass function to Xposed API

This commit is contained in:
2022-04-15 04:30:34 +08:00
parent 099ac65e55
commit b64c9a4d69
15 changed files with 287 additions and 21 deletions

View File

@@ -3,6 +3,7 @@
package="com.highcapable.yukihookapi.demo_module">
<application
android:name=".application.DemoApplication"
android:allowBackup="true"
android:icon="@mipmap/ic_icon"
android:label="@string/app_name"

View File

@@ -0,0 +1,39 @@
/*
* YukiHookAPI - An efficient Kotlin version of the Xposed Hook API.
* Copyright (C) 2019-2022 HighCapable
* https://github.com/fankes/YukiHookAPI
*
* MIT License
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
* This file is Created by fankes on 2022/4/15.
*/
package com.highcapable.yukihookapi.demo_module.application
import com.highcapable.yukihookapi.hook.log.loggerD
import com.highcapable.yukihookapi.hook.xposed.application.ModuleApplication
class DemoApplication : ModuleApplication() {
override fun onCreate() {
super.onCreate()
loggerD(msg = "I am running in module space")
}
}

View File

@@ -45,7 +45,8 @@ class HookEntry : YukiHookXposedInitProxy {
// 可简写为 configs {}
YukiHookAPI.configs {
// 全局调试用的 TAG
debugTag = "YukiHookAPI"
// 在 Logcat 控制台过滤此 TAG 可找到详细日志
debugTag = "YukiHookAPI-Demo"
// 是否开启调试模式
isDebug = true
// 是否启用调试日志的输出功能