30

I read through http://proguard.sourceforge.net/index.html#manual/usage.html but cannot get their differences.

I tested with 2 different options and decompiled the outcome. Both seems to produce the same result.

-keep class * implements android.os.Parcelable {
    *;
}

-keepclassmembers class * implements android.os.Parcelable {
    *;
}
TWiStErRob
  • 44,762
  • 26
  • 170
  • 254
Cheok Yan Cheng
  • 47,586
  • 132
  • 466
  • 875

1 Answers1

40

The first (-keep) will keep classes and class members that implement android.os.Parcelable from being removed or renamed.

The latter (-keepclassmembers) will keep class members only of classes that implement android.os.Parcelable from being removed or renamed.

TWiStErRob
  • 44,762
  • 26
  • 170
  • 254
user1592811
  • 903
  • 10
  • 5