gpt4 book ai didi

android - 将 Android 应用程序更新到最新的 Android M

转载 作者:太空宇宙 更新时间:2023-11-03 13:19:14 25 4
gpt4 key购买 nike

我想知道一个更好的方法来将我现有的项目更新到最新的 android M 以进行测试。有没有比我目前的方法更好的方法?

这是我基于此 Preview SDK 所做的事情

  1. 升级 Android Studio。
  2. 下载 SDK。
  3. 将 build.gradle 更新为 MNC。

所以现在,AS(android studio) 告诉我我需要将我的 java 更新到 1.7,因为 source 1.6 不支持 diamond operator。然后我在项目中的一些类报告Package xxx does not exist错误消息是否由API更新引起?如果是这样,那可能会给我一个线索,我会在android M中找到相应的API来修复它。

例如,更新后才出现以下错误。

Error:(43, 23) 错误:包 org.apache.http 不存在

我知道有一个 API 更改文档,但我想问你这是否是将 API 更新到最新版本的正常方法?

最佳答案

Does the error msg cause by API updates?

如果您指的是:

Error:(43, 23) error: package org.apache.http does not exist

然后是的,这是由 API 更新引起的,如 the HttpClient APIs were removed in Android M , 在 Android 5.1 中被弃用后。

if this is a normal way to updates the APIs to the latest release?

嗯,读书the documentation在执行上述任何步骤之前是个好主意。

开发者预览版也不同于常规操作系统版本,因为您不应发布针对预览版编译的应用。

否则,你所描述的肯定是起点。您可能想要进行哪些更改(例如,针对 the new permission system )将取决于您应用的性质。

关于android - 将 Android 应用程序更新到最新的 Android M,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31033957/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com