合并两个机器人项目 [英] merge two android projects

查看:230
本文介绍了合并两个机器人项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想合并两个不同的机器人项目,在一个项目中同时使用的functionalty。 他们使用的是完全不同的包中的文件。

i want to merge two different android projects to use the functionalty of both in one project. They are using complete different packages for the files.

我复制与不同的包中的文件的一个项目,但与清单文件有问题。

I copied the files with the different packages in one project, but there is a problem with the manifest file.

它是可能有不同的包在Android manifest文件? 或者,我怎么能解决这个问题?也许指定活动全包,而不是使用.shortcut?

Is it possibly to have different packages in the android manifest file? Or how can i solve this? Maybe specify the activities with the whole package and not use ".shortcut" ?

我希望有一个人帮我。

谢谢!

推荐答案

建立一个库就可以解决这个问题。这是我继续在我身边的一个类似的问题的方式:

Building a library can solve this problem. This is the way I have proceeded on my side for a similar question:

  • 我有一个项目项目A 这是完成和工作

我有一个新的项目项目B 这不得不重用项目A 的某些功能。

I had a new project ProjectB that had to reuse some functions of ProjectA.

这些功能有可能被再次重用所以我建了一个库 LIBRARY1 我感动必要$ C $从C 项目A 给它。我设置了 LIBRARY1 isLibrary 标志设置为true的Eclipse(这是在项目属性下的 - 让我知道你是否想了解更多细节,如果需要,我将编辑后)。

These functions were likely to be reused again so I built a library Library1 and I moved the necessary code from ProjectA to it. I set the Library1's isLibrary flag to true under Eclipse (that's in the project properties - let me know whether you would like more details on this and I'll edit that post if needed).

然后,我修改了项目A 的属性,使用 LIBRARY1 。这也意味着一些重构的项目A 的一面,这是确定的。

Then I modified the ProjectA's properties to use Library1. This also implied some refactoring on ProjectA side but that was OK.

最后,我建立了我的项目B LIBRARY1 ,以及一个客户端。这是简单的。

And finally, I created my ProjectB as a client of Library1 as well. And this was straightforward.

这篇关于合并两个机器人项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆