简体   繁体   English

为了与新的API版本兼容,是否需要重建Android应用

[英]To be compatible with a new API release does an Android app need to be rebuilt

To be compatible with a new API release does an Android app need to be rebuilt? 为了与新的API版本兼容,是否需要重建Android应用?

I have searched but cannot find any developer based notes advising this or anything remotely like this. 我已经搜索过,但是找不到任何基于开发人员的说明或类似建议。

I would think that it is something a developer does during the release preview (as part of good practice) but I also would have thought there should be no need because a new OS release must retain compatibility with an older app. 我认为这是开发人员在发布预览期间所做的事情(作为良好做法的一部分),但我也认为应该没有必要,因为新的OS版本必须保留与旧应用程序的兼容性。

Never the less I have seen first hand, and read comments about apps not refusing to work, laggy, etc. specifically in Lollipop. 尤其是在Lollipop中,我亲眼目睹了关于应用程序不拒绝工作,运行缓慢等方面的评论。

With each new OS release, the features and related methods are added to the existing set. 在每个新的OS版本中,功能和相关方法都添加到现有集中。 While addition of the new features(and its related methods in SDKs) continues, few things become obsolete with time. 尽管继续增加新功能(以及SDK中的相关方法),但随着时间的流逝,几乎没有什么东西变得过时了。 Such methods are then deprecated from SDKs. 然后从SDK中弃用此类方法。 These deprecated methods may work in some cases but it is always advised to use newer methods. 这些不推荐使用的方法在某些情况下可能会起作用,但始终建议使用更新的方法。

The published apps are developed with existing SDKs and it is developer's responsibility to make sure that it also works with newer releases. 已发布的应用程序是使用现有的SDK开发的,开发人员有责任确保它也可与较新的版本一起使用。 So it is a good practice to test your app with release preview and confirm that it doesn't break. 因此,使用发行版预览测试您的应用程序并确认它不会中断是一个好习惯。 You can not predict which methods will be getting deprecated so it is necessary that new OS release will be compatible to your app. 您无法预测不赞成使用哪些方法,因此有必要使新的OS版本与您的应用程序兼容。

To answer your question, it is not mandatory to rebuild the app with new API release. 要回答您的问题,使用新的API版本重建应用程序不是强制性的。 One should always first test it for compatibility with new API. 应该始终首先测试它与新API的兼容性。 If it breaks then it will become necessary to rebuild it to make it compatible. 如果损坏,则必须对其进行重建以使其兼容。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM