I want to make an library for android which can be used by other android apps as an dependencies. I know how to make an library from studio but please help me letting know, how to make files hidden from the library so that user can not see some files as in files there will be some token which i dont want to be viewed by the user who add that library in his android project.
Asked
Active
Viewed 39 times
0
-
Theoretically you could make these classes non-public (for example package local) and proguard them, but I'm not sure if it's a good idea. – Radek Kutyłowski Dec 30 '16 at 08:15
-
All in all they will be able to retrieve the token whatever you do, you can just make it harded to find. – Radek Kutyłowski Dec 30 '16 at 08:16
-
Checkout [this](https://inthecheesefactory.com/blog/how-to-upload-library-to-jcenter-maven-central-as-dependency/en) tutorial to publish a library and to hide certain parts of your library/code use proguard. See this [SO Answer](http://stackoverflow.com/questions/30526173/obfuscate-private-fields-using-proguard) to understand the obfuscation of private and protected methods. – Vipul Asri Dec 30 '16 at 08:40