如何将云端点产生sources.jar库到Android项目云端、如何将、项目、sources

由网友(丹蔻清纯)分享简介:谷歌Eclipse插件包含一个工具,可以自动生成的云终端客户端库。但是,似乎没有成为一个简单的方法来生成source.jar文件移动到你的Andr​​oid源代码。 Google Plugin for Eclipse includes a facility to automatically generate the...

谷歌Eclipse插件包含一个工具,可以自动生成的云终端客户端库。但是,似乎没有成为一个简单的方法来生成source.jar文件移动到你的Andr​​oid源代码。

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.

文档 https://developers.google.com/appengine/docs/爪哇/终端/ consume_android 说:

该端点产生导致源jar文件。添加   这个jar文件的内容对你的Andr​​oid项目。

The Endpoints generation results in a sources jar file. Add the contents of this jar file to your Android project.

这似乎并不可能把source.jar文件放到一个Android / lib或/库,因为源的.java而不是的.class的形式。所以,我只是手动复制在由GPE(它们放在一个端点-lib文件夹在你的AppEngine项目)产生的根源。尤其是当你有一个以上的终结点,并编辑它通常这可以是非常麻烦的。

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.

另请参见Error连接的Andr​​oid应用程序,以谷歌云终端:找不到类

有谁知道的一种方式实际直接使用sources.jar文件中的Andr​​oid项目?谢谢你。

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/

your-appengine-project/endpoint-libs/libYourEndpoint-v1/yourendpoint/yourendpoint-generated-source/

您可以在Eclipse中通过添加属性 - > Java的源链接建立这样做Path->来源链接

You can do this in Eclipse by adding a source link in Properties->Java Build Path->Source Link

在此您的Andr​​oid或客户端项目将看到使用Google->生成客户终端库产生的任何更改

After this your Android or client project will see any changes generated using "Google->Generate Client Endpoint Library"

阅读全文

相关推荐

最新文章