fengzhizi715 / SAF-AOP

android的AOP框架,支持android studio、gradle最新版本
Apache License 2.0
262 stars 52 forks source link

NOClassDefFoundError错误 #11

Open xiachengcheng opened 4 years ago

xiachengcheng commented 4 years ago

在项目中引进这个插件后,在activity的onCreate中进行hook,

  @HookMethod(beforeMethod = "foo")
    override fun onCreate(savedInstanceState: Bundle?) 

发生如下错误 java.lang.NoClassDefFoundError: Failed resolution of: Lcom/safframework/tony/common/utils/Preconditions; at com.safframework.aop.HookMethodAspect.hookMethod(HookMethodAspect.java:48) at com.project.android.apps.gccm.FrameworkActivity.onCreate(FrameworkActivity.kt:131)

foo已经定义:

private fun foo(){
        Log.e("Test123", "empty input param")
    }

这个是什么原因造成的呢?不支持kotlin吗?

kotlinic commented 3 years ago

这么项目代码应该没开源完整,上传发布的saf-injectview 也是旧的不完整