Replace optIn function

This commit is contained in:
2022-04-03 15:16:48 +08:00
parent de402ecd7a
commit af7dcb41a9
22 changed files with 77 additions and 164 deletions

9
.idea/kotlinc.xml generated Normal file
View File

@@ -0,0 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="Kotlin2JvmCompilerArguments">
<option name="jvmTarget" value="11" />
</component>
<component name="KotlinCompilerSettings">
<option name="additionalArguments" value="-version -Xopt-in=kotlin.RequiresOptIn" />
</component>
</project>

View File

@@ -230,9 +230,7 @@ class YukiHookXposedProcessor : SymbolProcessorProvider {
).apply {
/** 插入 xposed_init 代码 */
write(
("@file:Suppress(\"OPT_IN_USAGE\", \"EXPERIMENTAL_API_USAGE\")\n" +
"\n" +
"package $packageName\n" +
("package $packageName\n" +
"\n" +
"import androidx.annotation.Keep\n" +
"import com.highcapable.yukihookapi.YukiHookAPI\n" +
@@ -243,6 +241,7 @@ class YukiHookXposedProcessor : SymbolProcessorProvider {
"import de.robv.android.xposed.XposedHelpers\n" +
"import de.robv.android.xposed.XposedBridge\n" +
"import de.robv.android.xposed.callbacks.XC_LoadPackage\n" +
"import com.highcapable.yukihookapi.annotation.DoNotUseAPI\n" +
"import $packageName.$className\n" +
"\n" +
"/**\n" +
@@ -257,6 +256,7 @@ class YukiHookXposedProcessor : SymbolProcessorProvider {
" * Powered by YukiHookAPI (C) HighCapable 2022\n" +
" */\n" +
"@Keep\n" +
"@DoNotUseAPI\n" +
"class $className$xposedClassShortName : IXposedHookLoadPackage {\n" +
"\n" +
" override fun handleLoadPackage(lpparam: XC_LoadPackage.LoadPackageParam?) {\n" +

View File

@@ -18,7 +18,14 @@ javadoc {
if (JavaVersion.current().isJava9Compatible()) options.addBooleanOption('html5', true)
}
kotlin { sourceSets.main { kotlin.srcDir("src/api/kotlin") } }
kotlin {
sourceSets.main { kotlin.srcDir("src/api/kotlin") }
sourceSets { all { languageSettings { optIn('com.highcapable.yukihookapi.annotation.DoNotUseAPI') } } }
}
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile).configureEach {
kotlinOptions { freeCompilerArgs += "-opt-in=com.highcapable.yukihookapi.annotation.DoNotUseAPI" }
}
dependencies {
// Used 82 API Version

View File

@@ -25,7 +25,7 @@
*
* This file is Created by fankes on 2022/2/2.
*/
@file:Suppress("MemberVisibilityCanBePrivate", "unused", "OPT_IN_USAGE", "EXPERIMENTAL_API_USAGE")
@file:Suppress("MemberVisibilityCanBePrivate", "unused")
package com.highcapable.yukihookapi
@@ -33,8 +33,7 @@ import android.app.Application
import android.content.Context
import com.highcapable.yukihookapi.YukiHookAPI.configs
import com.highcapable.yukihookapi.YukiHookAPI.encase
import com.highcapable.yukihookapi.annotation.DoNotUseField
import com.highcapable.yukihookapi.annotation.DoNotUseMethod
import com.highcapable.yukihookapi.annotation.DoNotUseAPI
import com.highcapable.yukihookapi.hook.core.finder.ConstructorFinder
import com.highcapable.yukihookapi.hook.core.finder.FieldFinder
import com.highcapable.yukihookapi.hook.core.finder.MethodFinder
@@ -84,7 +83,7 @@ object YukiHookAPI {
* - ❗此变量为私有功能性 API - 你不应该手动调用此变量
* @return [Boolean]
*/
@DoNotUseField
@DoNotUseAPI
val isXposedCallbackSetUp
get() = !isXposedInitialized && packageParamCallback != null
@@ -93,7 +92,7 @@ object YukiHookAPI {
*
* - ❗这是私有 API - 请勿手动修改 - 会引发未知异常
*/
@DoNotUseField
@DoNotUseAPI
var isModulePackageXposedEnv = false
/**
@@ -101,7 +100,7 @@ object YukiHookAPI {
*
* - ❗这是私有 API - 请勿手动修改 - 会引发未知异常
*/
@DoNotUseField
@DoNotUseAPI
var modulePackageName = ""
/**
@@ -214,7 +213,7 @@ object YukiHookAPI {
*
* - ❗装载代码将自动生成 - 你不应该手动使用此方法装载 Xposed 模块事件
*/
@DoNotUseMethod
@DoNotUseAPI
fun onXposedInitialized() {
isXposedInitialized = true
}
@@ -225,7 +224,7 @@ object YukiHookAPI {
* - ❗装载代码将自动生成 - 你不应该手动使用此方法装载 Xposed 模块事件
* @param lpparam Xposed [XC_LoadPackage.LoadPackageParam]
*/
@DoNotUseMethod
@DoNotUseAPI
fun onXposedLoaded(lpparam: XC_LoadPackage.LoadPackageParam) =
packageParamCallback?.invoke(
PackageParam(

View File

@@ -23,15 +23,19 @@
* 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/2/2.
* This file is Created by fankes on 2022/4/3.
*/
@file:Suppress("OPT_IN_IS_NOT_ENABLED", "EXPERIMENTAL_IS_NOT_ENABLED")
package com.highcapable.yukihookapi.annotation
@RequiresOptIn(level = RequiresOptIn.Level.WARNING)
@RequiresOptIn(level = RequiresOptIn.Level.ERROR)
@MustBeDocumented
@Target(
AnnotationTarget.CLASS,
AnnotationTarget.CONSTRUCTOR,
AnnotationTarget.FUNCTION,
AnnotationTarget.ANNOTATION_CLASS,
AnnotationTarget.PROPERTY,
AnnotationTarget.FIELD,
AnnotationTarget.LOCAL_VARIABLE,
@@ -42,10 +46,8 @@ package com.highcapable.yukihookapi.annotation
)
@Retention(AnnotationRetention.BINARY)
/**
* - 警告方法外部调用声明
* - 不可在非指定区域被使用的隐藏 API
*
* 方法除继承和接口外不应该在这里被调用
*
* 如果调用此方法可能会出现错误或 APP 发生异常
* 功能除继承和接口外不应该在这里被调用
*/
annotation class DoNotUseField
annotation class DoNotUseAPI

View File

@@ -1,46 +0,0 @@
/*
* 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/2/2.
*/
@file:Suppress("OPT_IN_IS_NOT_ENABLED", "EXPERIMENTAL_IS_NOT_ENABLED")
package com.highcapable.yukihookapi.annotation
@RequiresOptIn(level = RequiresOptIn.Level.WARNING)
@MustBeDocumented
@Target(
AnnotationTarget.CLASS,
AnnotationTarget.ANNOTATION_CLASS
)
@Retention(AnnotationRetention.BINARY)
/**
* - ❗警告方法外部调用声明
*
* 此方法除继承和接口外不应该在这里被调用
*
* 如果调用此方法可能会出现错误或 APP 发生异常
*/
annotation class DoNotUseClass

View File

@@ -1,46 +0,0 @@
/*
* 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/2/2.
*/
@file:Suppress("OPT_IN_IS_NOT_ENABLED", "EXPERIMENTAL_IS_NOT_ENABLED")
package com.highcapable.yukihookapi.annotation
@RequiresOptIn(level = RequiresOptIn.Level.WARNING)
@MustBeDocumented
@Target(
AnnotationTarget.CONSTRUCTOR,
AnnotationTarget.FUNCTION
)
@Retention(AnnotationRetention.BINARY)
/**
* - ❗警告方法外部调用声明
*
* 此方法除继承和接口外不应该在这里被调用
*
* 如果调用此方法可能会出现错误或 APP 发生异常
*/
annotation class DoNotUseMethod

View File

@@ -25,13 +25,13 @@
*
* This file is Created by fankes on 2022/2/2.
*/
@file:Suppress("MemberVisibilityCanBePrivate", "unused", "OPT_IN_USAGE", "EXPERIMENTAL_API_USAGE")
@file:Suppress("MemberVisibilityCanBePrivate", "unused")
package com.highcapable.yukihookapi.hook.core
import android.os.SystemClock
import com.highcapable.yukihookapi.YukiHookAPI
import com.highcapable.yukihookapi.annotation.DoNotUseMethod
import com.highcapable.yukihookapi.annotation.DoNotUseAPI
import com.highcapable.yukihookapi.hook.bean.HookClass
import com.highcapable.yukihookapi.hook.core.finder.ConstructorFinder
import com.highcapable.yukihookapi.hook.core.finder.FieldFinder
@@ -96,7 +96,7 @@ class YukiHookCreater(private val packageParam: PackageParam, private val hookCl
* @throws IllegalStateException 如果必要参数没有被设置
* @return [Result]
*/
@DoNotUseMethod
@DoNotUseAPI
fun hook(): Result {
if (YukiHookAPI.hasXposedBridge.not()) return Result()
return if (hookMembers.isEmpty()) error("Hook Members is empty,hook aborted")
@@ -370,7 +370,7 @@ class YukiHookCreater(private val packageParam: PackageParam, private val hookCl
* - ❗此功能交由方法体自动完成 - 你不应该手动调用此方法
* @return [Result]
*/
@DoNotUseMethod
@DoNotUseAPI
fun build() = Result()
/**
@@ -378,7 +378,7 @@ class YukiHookCreater(private val packageParam: PackageParam, private val hookCl
*
* - ❗此功能交由方法体自动完成 - 你不应该手动调用此方法
*/
@DoNotUseMethod
@DoNotUseAPI
fun hook() {
if (YukiHookAPI.hasXposedBridge.not() || isDisableMemberRunHook) return
if (hookClass.instance == null) {

View File

@@ -25,14 +25,11 @@
*
* This file is Created by fankes on 2022/2/4.
*/
@file:Suppress(
"unused", "OPT_IN_USAGE", "EXPERIMENTAL_API_USAGE",
"MemberVisibilityCanBePrivate", "UNCHECKED_CAST", "KotlinConstantConditions"
)
@file:Suppress("unused", "MemberVisibilityCanBePrivate", "UNCHECKED_CAST", "KotlinConstantConditions")
package com.highcapable.yukihookapi.hook.core.finder
import com.highcapable.yukihookapi.annotation.DoNotUseMethod
import com.highcapable.yukihookapi.annotation.DoNotUseAPI
import com.highcapable.yukihookapi.hook.core.YukiHookCreater
import com.highcapable.yukihookapi.hook.core.finder.base.BaseFinder
import com.highcapable.yukihookapi.hook.core.finder.type.ModifierRules
@@ -150,7 +147,7 @@ class ConstructorFinder(
* - ❗此功能交由方法体自动完成 - 你不应该手动调用此方法
* @return [Result]
*/
@DoNotUseMethod
@DoNotUseAPI
override fun build(isBind: Boolean) = try {
if (classSet != null) {
runBlocking {
@@ -171,7 +168,7 @@ class ConstructorFinder(
* @param throwable 异常
* @return [Result]
*/
@DoNotUseMethod
@DoNotUseAPI
override fun failure(throwable: Throwable?) = Result(isNoSuch = true, throwable)
/**
@@ -200,7 +197,7 @@ class ConstructorFinder(
*
* - ❗此功能交由方法体自动完成 - 你不应该手动调用此方法
*/
@DoNotUseMethod
@DoNotUseAPI
internal fun build() {
if (classSet == null) return
if (remedyPlans.isNotEmpty()) run {

View File

@@ -25,12 +25,12 @@
*
* This file is Created by fankes on 2022/2/4.
*/
@file:Suppress("unused", "UNCHECKED_CAST", "MemberVisibilityCanBePrivate", "OPT_IN_USAGE", "EXPERIMENTAL_API_USAGE")
@file:Suppress("unused", "UNCHECKED_CAST", "MemberVisibilityCanBePrivate")
package com.highcapable.yukihookapi.hook.core.finder
import android.os.SystemClock
import com.highcapable.yukihookapi.annotation.DoNotUseMethod
import com.highcapable.yukihookapi.annotation.DoNotUseAPI
import com.highcapable.yukihookapi.hook.core.YukiHookCreater
import com.highcapable.yukihookapi.hook.core.finder.base.BaseFinder
import com.highcapable.yukihookapi.hook.core.finder.type.ModifierRules
@@ -123,7 +123,7 @@ class FieldFinder(
* @return [Result]
* @throws IllegalStateException 如果 [name] 没有被设置
*/
@DoNotUseMethod
@DoNotUseAPI
override fun build(isBind: Boolean) = try {
if (classSet != null) {
runBlocking {
@@ -147,7 +147,7 @@ class FieldFinder(
* @param throwable 异常
* @return [Result]
*/
@DoNotUseMethod
@DoNotUseAPI
override fun failure(throwable: Throwable?) = Result(isNoSuch = true, throwable)
/**

View File

@@ -25,14 +25,11 @@
*
* This file is Created by fankes on 2022/2/4.
*/
@file:Suppress(
"unused", "MemberVisibilityCanBePrivate",
"OPT_IN_USAGE", "EXPERIMENTAL_API_USAGE", "UNCHECKED_CAST", "KotlinConstantConditions"
)
@file:Suppress("unused", "MemberVisibilityCanBePrivate", "UNCHECKED_CAST", "KotlinConstantConditions")
package com.highcapable.yukihookapi.hook.core.finder
import com.highcapable.yukihookapi.annotation.DoNotUseMethod
import com.highcapable.yukihookapi.annotation.DoNotUseAPI
import com.highcapable.yukihookapi.hook.core.YukiHookCreater
import com.highcapable.yukihookapi.hook.core.finder.base.BaseFinder
import com.highcapable.yukihookapi.hook.core.finder.type.ModifierRules
@@ -195,7 +192,7 @@ class MethodFinder(
* @param isBind 是否将结果设置到目标 [YukiHookCreater.MemberHookCreater]
* @return [Result]
*/
@DoNotUseMethod
@DoNotUseAPI
override fun build(isBind: Boolean) = try {
if (classSet != null) {
runBlocking {
@@ -216,7 +213,7 @@ class MethodFinder(
* @param throwable 异常
* @return [Result]
*/
@DoNotUseMethod
@DoNotUseAPI
override fun failure(throwable: Throwable?) = Result(isNoSuch = true, throwable)
/**
@@ -246,7 +243,7 @@ class MethodFinder(
*
* - ❗此功能交由方法体自动完成 - 你不应该手动调用此方法
*/
@DoNotUseMethod
@DoNotUseAPI
internal fun build() {
if (classSet == null) return
if (remedyPlans.isNotEmpty()) run {

View File

@@ -29,7 +29,7 @@ package com.highcapable.yukihookapi.hook.core.finder.base
import android.os.SystemClock
import com.highcapable.yukihookapi.YukiHookAPI
import com.highcapable.yukihookapi.annotation.DoNotUseMethod
import com.highcapable.yukihookapi.annotation.DoNotUseAPI
import com.highcapable.yukihookapi.hook.core.YukiHookCreater
import com.highcapable.yukihookapi.hook.log.yLoggerE
import com.highcapable.yukihookapi.hook.log.yLoggerI
@@ -164,7 +164,7 @@ abstract class BaseFinder(
* @param isBind 是否将结果设置到目标 [YukiHookCreater.MemberHookCreater]
* @return [Any]
*/
@DoNotUseMethod
@DoNotUseAPI
abstract fun build(isBind: Boolean = false): Any
/**
@@ -174,6 +174,6 @@ abstract class BaseFinder(
* @param throwable 异常
* @return [Any]
*/
@DoNotUseMethod
@DoNotUseAPI
abstract fun failure(throwable: Throwable?): Any
}

View File

@@ -28,7 +28,7 @@
package com.highcapable.yukihookapi.hook.entity
import com.highcapable.yukihookapi.YukiHookAPI
import com.highcapable.yukihookapi.annotation.DoNotUseMethod
import com.highcapable.yukihookapi.annotation.DoNotUseAPI
import com.highcapable.yukihookapi.annotation.xposed.InjectYukiHookWithXposed
import com.highcapable.yukihookapi.hook.param.PackageParam
import com.highcapable.yukihookapi.hook.xposed.proxy.YukiHookXposedInitProxy
@@ -58,7 +58,7 @@ abstract class YukiBaseHooker : PackageParam() {
* - ❗此方法为私有功能性 API - 你不应该手动调用此方法
* @param packageParam 需要使用的 [PackageParam]
*/
@DoNotUseMethod
@DoNotUseAPI
internal fun assignInstance(packageParam: PackageParam) {
baseAssignInstance(packageParam)
onHook()

View File

@@ -25,7 +25,7 @@
*
* This file is Created by fankes on 2022/2/2.
*/
@file:Suppress("unused", "OPT_IN_USAGE", "EXPERIMENTAL_API_USAGE")
@file:Suppress("unused")
package com.highcapable.yukihookapi.hook.factory

View File

@@ -25,7 +25,7 @@
*
* This file is Created by fankes on 2022/2/2.
*/
@file:Suppress("unused", "OPT_IN_USAGE", "EXPERIMENTAL_API_USAGE")
@file:Suppress("unused")
package com.highcapable.yukihookapi.hook.factory

View File

@@ -25,7 +25,7 @@
*
* This file is Created by fankes on 2022/2/2.
*/
@file:Suppress("unused", "MemberVisibilityCanBePrivate", "UNCHECKED_CAST", "OPT_IN_USAGE", "EXPERIMENTAL_API_USAGE")
@file:Suppress("unused", "MemberVisibilityCanBePrivate", "UNCHECKED_CAST")
package com.highcapable.yukihookapi.hook.param

View File

@@ -25,13 +25,13 @@
*
* This file is Created by fankes on 2022/2/2.
*/
@file:Suppress("unused", "MemberVisibilityCanBePrivate", "OPT_IN_USAGE", "EXPERIMENTAL_API_USAGE")
@file:Suppress("unused", "MemberVisibilityCanBePrivate")
package com.highcapable.yukihookapi.hook.param
import android.app.Application
import android.content.pm.ApplicationInfo
import com.highcapable.yukihookapi.annotation.DoNotUseMethod
import com.highcapable.yukihookapi.annotation.DoNotUseAPI
import com.highcapable.yukihookapi.hook.bean.HookClass
import com.highcapable.yukihookapi.hook.bean.VariousClass
import com.highcapable.yukihookapi.hook.core.YukiHookCreater
@@ -109,7 +109,7 @@ open class PackageParam(private var wrapper: PackageParamWrapper? = null) {
* - ❗此方法为私有功能性 API - 你不应该手动调用此方法
* @param anotherParam 另一个 [PackageParam]
*/
@DoNotUseMethod
@DoNotUseAPI
internal fun baseAssignInstance(anotherParam: PackageParam) {
thisParam.wrapper = anotherParam.wrapper
}

View File

@@ -27,7 +27,7 @@
*/
package com.highcapable.yukihookapi.hook.param.wrapper
import com.highcapable.yukihookapi.annotation.DoNotUseClass
import com.highcapable.yukihookapi.annotation.DoNotUseAPI
import com.highcapable.yukihookapi.hook.param.HookParam
import de.robv.android.xposed.XC_MethodHook
import de.robv.android.xposed.XposedBridge
@@ -39,7 +39,7 @@ import java.lang.reflect.Member
* - ❗这是一个私有 API - 请不要在外部使用
* @param baseParam 对接 [XC_MethodHook.MethodHookParam]
*/
@DoNotUseClass
@DoNotUseAPI
class HookParamWrapper(private val baseParam: XC_MethodHook.MethodHookParam) {
/**

View File

@@ -25,12 +25,12 @@
*
* This file is Created by fankes on 2022/2/7.
*/
@file:Suppress("unused", "MemberVisibilityCanBePrivate", "OPT_IN_USAGE", "EXPERIMENTAL_API_USAGE")
@file:Suppress("unused", "MemberVisibilityCanBePrivate")
package com.highcapable.yukihookapi.hook.param.wrapper
import android.content.pm.ApplicationInfo
import com.highcapable.yukihookapi.annotation.DoNotUseClass
import com.highcapable.yukihookapi.annotation.DoNotUseAPI
import com.highcapable.yukihookapi.hook.param.PackageParam
/**
@@ -42,7 +42,7 @@ import com.highcapable.yukihookapi.hook.param.PackageParam
* @param appClassLoader APP [ClassLoader]
* @param appInfo APP [ApplicationInfo]
*/
@DoNotUseClass
@DoNotUseAPI
class PackageParamWrapper(
var packageName: String,
var processName: String,

View File

@@ -25,19 +25,16 @@
*
* This file is Created by fankes on 2022/2/5.
*/
@file:Suppress("OPT_IN_USAGE", "EXPERIMENTAL_API_USAGE")
package com.highcapable.yukihookapi.hook.utils
import com.highcapable.yukihookapi.annotation.DoNotUseClass
import com.highcapable.yukihookapi.annotation.DoNotUseMethod
import com.highcapable.yukihookapi.annotation.DoNotUseAPI
/**
* 计算方法执行耗时
* @param block 方法块
* @return [RunBlockResult]
*/
@DoNotUseMethod
@DoNotUseAPI
inline fun <R> runBlocking(block: () -> R): RunBlockResult {
val start = System.currentTimeMillis()
block()
@@ -48,7 +45,7 @@ inline fun <R> runBlocking(block: () -> R): RunBlockResult {
* 构造耗时计算结果类
* @param after 耗时
*/
@DoNotUseClass
@DoNotUseAPI
class RunBlockResult(private val after: Long) {
/**

View File

@@ -29,7 +29,7 @@ package com.highcapable.yukihookapi.hook.xposed
import android.app.Activity
import androidx.annotation.Keep
import com.highcapable.yukihookapi.annotation.DoNotUseMethod
import com.highcapable.yukihookapi.annotation.DoNotUseAPI
import com.highcapable.yukihookapi.hook.factory.isModuleActive
import com.highcapable.yukihookapi.hook.factory.isTaiChiModuleActive
import com.highcapable.yukihookapi.hook.factory.isXposedModuleActive
@@ -92,7 +92,7 @@ object YukiHookModuleStatus {
* @return [Boolean]
*/
@Keep
@DoNotUseMethod
@DoNotUseAPI
@JvmName(IS_ACTIVE_METHOD_NAME)
internal fun isActive(): Boolean {
yLoggerD(msg = IS_ACTIVE_METHOD_NAME, isDisableLog = true)

View File

@@ -25,10 +25,7 @@
*
* This file is Created by fankes on 2022/2/8.
*/
@file:Suppress(
"OPT_IN_USAGE", "EXPERIMENTAL_API_USAGE", "SetWorldReadable", "CommitPrefEdits",
"DEPRECATION", "WorldReadableFiles", "unused"
)
@file:Suppress("SetWorldReadable", "CommitPrefEdits", "DEPRECATION", "WorldReadableFiles", "unused")
package com.highcapable.yukihookapi.hook.xposed.prefs