mirror of
https://github.com/HighCapable/YukiHookAPI.git
synced 2025-09-06 02:35:40 +08:00
Added contains function in YukiHookModulePrefs
This commit is contained in:
@@ -399,7 +399,18 @@ class YukiHookModulePrefs private constructor(private var context: Context? = nu
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取全部存储的键值数据
|
||||
* 判断当前是否包含 [key] 键值的数据
|
||||
*
|
||||
* - 智能识别对应环境读取键值数据
|
||||
* @return [Boolean] 是否包含
|
||||
*/
|
||||
fun contains(key: String) =
|
||||
if (isXposedEnvironment)
|
||||
xPrefs.contains(key)
|
||||
else sPrefs.contains(key)
|
||||
|
||||
/**
|
||||
* 获取全部存储的键值数据
|
||||
*
|
||||
* - 智能识别对应环境读取键值数据
|
||||
*
|
||||
|
Reference in New Issue
Block a user