Android proguard, keep inner class

后端 未结 6 1690
故里飘歌
故里飘歌 2020-11-30 07:12

My android program has a class A, which has two static inner class. They are found to be stripped from .dex after applying proguard.

6条回答
  •  一整个雨季
    2020-11-30 07:35

    Your configuration looks correct. You should double-check that you haven't misspelled the class names. If the spelling in incorrect, ProGuard should print out a note about it. You can also specify -printseeds seeds.txt, and see if your classes are listed in the resulting file. If they are listed, the classes are also in the processed code.

    As Alexander Lucas mentioned, you may also want to keep the fields and methods of these classes -- that depends on your requirements.

提交回复
热议问题