Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

In proguard, what is the keyword to preserve package/default access variables and methods?

Tags:

java

proguard

ant

You can say:

-keepclassmembers class sun.** {
    public protected *;
}

But I am not excluding package/default access methods :(

void myMethod {

}
like image 594
TraderJenny Avatar asked Oct 03 '14 17:10

TraderJenny


1 Answers

You can add another -keepclassmembers like that:

-keepclassmembers class com.mycompany.MyClass {
  !public !protected !private *;
}
like image 150
rdalmeida Avatar answered Sep 28 '22 06:09

rdalmeida