自 2025 年 3 月 27 日起,我们建议您使用 android-latest-release
而非 aosp-main
构建 AOSP 并为其做出贡献。如需了解详情,请参阅 AOSP 的变更。
允许的 Android 7.0 版本字符串
使用集合让一切井井有条
根据您的偏好保存内容并对其进行分类。
如 Android 7.0 兼容性定义第 3.2.2 节所述,系统属性 android.os.Build.VERSION.RELEASE
只能使用特定字符串。这是因为应用和网站可能需要该字符串具有可预测的值,以便最终用户能够轻松可靠地识别其设备搭载的 Android 版本。
由于 Android 软件的后续版本可能会修改该字符串,但不会更改任何 API 行为,因此这些版本可能不会附带新的兼容性定义文档。此页中列出了基于 Android 7.0 的系统所允许的版本。对于 Android 7.0 而言,android.os.Build.VERSION.RELEASE
只能使用以下值:
本页面上的内容和代码示例受内容许可部分所述许可的限制。Java 和 OpenJDK 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2025-07-27。
[[["易于理解","easyToUnderstand","thumb-up"],["解决了我的问题","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["没有我需要的信息","missingTheInformationINeed","thumb-down"],["太复杂/步骤太多","tooComplicatedTooManySteps","thumb-down"],["内容需要更新","outOfDate","thumb-down"],["翻译问题","translationIssue","thumb-down"],["示例/代码问题","samplesCodeIssue","thumb-down"],["其他","otherDown","thumb-down"]],["最后更新时间 (UTC):2025-07-27。"],[],[],null,["# Permitted version strings for Android 7.0\n\nAs described in Section 3.2.2 of the [Android 7.0 Compatibility Definition](/static/docs/compatibility/7.0/android-7.0-cdd.pdf),\nonly certain strings are allowable for the system property\n`android.os.Build.VERSION.RELEASE`. The reason for this is that\napplications and web sites may rely on predictable values for this string, and\nso that end users can easily and reliably identify the version of Android\nrunning on their devices.\n\nBecause subsequent releases of the Android software may revise this string,\nbut not change any API behavior, such releases may not be accompanied by a new\nCompatibility Definition Document. This page lists the versions that are\nallowable by an Android 7.0-based system. The only permitted values for\n`android.os.Build.VERSION.RELEASE` for Android 7.0 are:\n\n- 7.0"]]