Google Plugin for Eclipse includes a facility to automatically generate the cloud endpoints client library. But there doesn't seem to be an easy way to move the generated source.jar file into your Android source.
The documentation https://developers.google.com/appengine/docs/java/endpoints/consume_android says
The Endpoints generation results in a sources jar file. Add the contents of this jar file to your Android project.
It doesn't seem possible to put the source.jar file into an Android /lib or /libs, since the source is .java rather than .class form. So I just manually copy over the source generated by GPE (which they put in an endpoints-lib folder in your AppEngine project). This can be extremely cumbersome especially when you have more than one endpoint and are editing it often.
See also Error connecting android app to Google Cloud Endpoints: could not find class
Does anyone know of a way to actually use the sources.jar file directly in the Android project? Thanks.
This problem is solved in Eclipse by adding a linked resource to the directory at
your-appengine-project/endpoint-libs/libYourEndpoint-v1/yourendpoint/yourendpoint-generated-source/
You can do this in Eclipse by adding a source link in Properties->Java Build Path->Source Link
After this your Android or client project will see any changes generated using "Google->Generate Client Endpoint Library"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With