I’ve written an Android app which various abstract classes that perform useful functions. These functions could be leveraged in other apps.
I want to share a class module with another programmer, but I don’t want to share the source code. I would like to share a .class file but I’m not sure how to do the following:
- Compile an Android .java file into .class
- What does the receiver of the .class file have to do to use that .class in their project? (using Eclipse environment)
You would share it using a .jar file. Eclipse has a wizard for exporting your classes as a jar file.
To import it into your Android project in Eclipse:
https://developer.android.com/guide/appendix/faq/commontasks.html#addexternallibrary