我遇到了一个奇怪的NoClassDefFoundError
,因为“NoClassDefFound的类”存在:
Fatal Exception: java.lang.NoClassDefFoundError: cn.dreamtobe.babyguard.b.a$e
at cn.dreamtobe.babyguard.data.BabyGuardDatabase.repealLastAction(BabyGuardDatabase.kt:109)
at cn.dreamtobe.babyguard.data.BabyGuardDatabase$show$1.onClick(BabyGuardDatabase.kt:192)
at android.support.design.widget.Snackbar$1.onClick(Snackbar.java:255)
at android.view.View.performClick(View.java:5207)
at android.view.View.onKeyUp(View.java:9893)
at android.widget.TextView.onKeyUp(TextView.java:6201)
at android.view.KeyEvent.dispatch(KeyEvent.java:2667)
at android.view.View.dispatchKeyEvent(View.java:9245)
cn.dreamtobe.babyguard.b.a$e
存在:Proguard one
来源
答案 0 :(得分:1)
java.util.ArrayList#removeIf
方法被添加到Java 8中的ArrayList,以及功能接口(例如Predicate)。您可以使用Kotlin instaed的filterNot
。