AbstractComposableLanguage

Description: TODO

Author

M8Test, [email protected], https://m8test.com

Constructors

Link copied to clipboard
constructor(apkPluginProvider: ApkPluginProvider)

Functions

Link copied to clipboard

直接添加一个 DexClassLoader .

abstract fun addClassLoader(classLoaderConfig: DexClassLoaderConfig.() -> Unit): BaseDexClassLoader?

添加一个 DexClassLoader .

Link copied to clipboard
abstract fun configureClassLoader(classLoaderConfig: DexClassLoaderConfig.() -> Unit)

配置 DexClassLoader , 一般用于排除指定的类, 如果找不到 DexClassLoader 会抛异常.

abstract fun configureClassLoader(dexClassLoader: BaseDexClassLoader, classLoaderConfig: DexClassLoaderConfig.() -> Unit)

配置指定的 DexClassLoader , 如果找不到 DexClassLoader 会抛异常.

Link copied to clipboard
abstract fun createClassLoader(classLoaderConfig: DexClassLoaderConfig.() -> Unit): BaseDexClassLoader

新建一个 DexClassLoader .

Link copied to clipboard
abstract fun createScript(scriptEngine: ScriptEngine, scriptContext: ScriptContext, scriptConfig: ScriptConfig): Script<*>

创建脚本.

Link copied to clipboard
abstract fun getApplication(): Application

获取 android 的 Application 对象.

Link copied to clipboard

获取构建插件提供器的类, 实现接口 com.m8test.script.builder.api.BuildPluginProvider, 必须要有无参构造函数, 因为需要通过反射调用.

Link copied to clipboard

获取插件的类加载器.

Link copied to clipboard

获取所有的 DexClassLoader .

Link copied to clipboard
open fun getExtensionIconId(extension: String): Int?

获取扩展名对应的图标 id.

Link copied to clipboard

获取语言支持的所有扩展.

Link copied to clipboard
abstract fun getFilesDir(): File

获取插件安装路径.

Link copied to clipboard
abstract fun getName(): String

获取插件名.

Link copied to clipboard
abstract fun getPackageInfo(): PackageInfo

获取 apk 插件的 PackageInfo 对象.

Link copied to clipboard
abstract override fun getPluginInfo(): PluggableApkPluginInfo

获取插件信息.

Link copied to clipboard
abstract fun getResources(): Resources

获取 apk 插件的 Resources 对象.

Link copied to clipboard

获取插件配置信息.

Link copied to clipboard
abstract fun getVariablePrefix(): String

获取变量名前缀.

Link copied to clipboard
abstract fun getVariableSuffix(): String

获取变量名后缀.

Link copied to clipboard
open fun isExtensionValid(extension: String): Boolean

判断语言是否可以处理给定的扩展名.

Link copied to clipboard
abstract fun loadClass(className: String): Class<*>

加载指定的类.

Link copied to clipboard
abstract fun removeClassLoader(classLoader: BaseDexClassLoader): Boolean

移除一个 DexClassLoader .