【发布时间】:2020-08-04 13:27:16
【问题描述】:
如果我想保留内部类,我使用-keep public class com.example.MyClass$MyInnerClass { *; }(或-keep public class com.example.MyClass$* { *; } 保留任何多个内部类)。
问题:是否有可能保留一个类的所有内部类,通过扩展或实现来匹配签名?
interface MyInterface { fun foo() }
class Foo : MyInterface {
override fun foo() {}
class Inner // <- keep these with one rule for all `MyInterface` implementations
class Another // <- keep these with one rule for all `MyInterface` implementations
}
class Bar : MyInterface {
override fun foo() {}
class Third // <- keep these with one rule for all `MyInterface` implementations
class Fourth // <- keep these with one rule for all `MyInterface` implementations
}
类似-keep public class (com.example.** implements io.foo.bar.MyInterface)$*
【问题讨论】:
标签: proguard obfuscation android-r8