限制裝置端 Android 容器的載入
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
「裝置端 Android 容器」是指在 Android 裝置上模擬 Android 作業系統的應用程式。這包括模擬整個 Android 作業系統的應用程式,以及僅模擬部分 Android 作業系統的應用程式。
如果不希望裝置端 Android 容器應用程式載入您的 Play 商店應用程式,或是擔任您 Play 商店應用程式的 Proxy 服務,您可以在應用程式資訊清單中加入字串來宣告此限制。
在 Android 資訊清單的 <application>
下建立屬性,並將 android:name
和 android:value
分別設為 REQUIRE_SECURE_ENV
和 1:
<property android:name="REQUIRE_SECURE_ENV" android:value="1" />
針對此用途,您可以使用 REQUIRE_SECURE_ENV
屬性,無論應用程式執行的 Android 版本為何都可以。
裝置端 Android 容器應用程式必須遵循這項宣告。
如要進一步瞭解裝置端 Android 容器,請參閱說明中心。
這個頁面中的內容和程式碼範例均受《內容授權》中的授權所規範。Java 與 OpenJDK 是 Oracle 和/或其關係企業的商標或註冊商標。
上次更新時間:2024-01-10 (世界標準時間)。
[[["容易理解","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"]],["上次更新時間:2024-01-10 (世界標準時間)。"],[],[],null,["# Limit loading in on-device Android containers\n\n*On-device Android containers* are apps that simulate the Android OS on an\nAndroid-powered device. This includes both apps that simulate the Android OS in\nits entirety and apps that only simulate portions of the Android OS.\n\nIf you don't want on-device Android container apps to load in or proxy your Play\nStore app, you can add a string to your app manifest that declares this\nrestriction.\n\nCreate a [property](/guide/topics/manifest/property-element) under the\n[`\u003capplication\u003e`](/guide/topics/manifest/application-element) in your Android\nmanifest with `android:name` set to `REQUIRE_SECURE_ENV` and `android:value` set\nto 1: \n\n \u003cproperty android:name=\"REQUIRE_SECURE_ENV\" android:value=\"1\" /\u003e\n\nFor this use case, you can use the `REQUIRE_SECURE_ENV` property regardless of\nthe Android version that your app runs on.\n\nOn-device Android container apps are\n[required](https://support.google.com/googleplay/android-developer/answer/9888379)\nto respect this declaration.\n\nFor more information about on-device Android containers, see the [Help\nCenter](https://support.google.com/googleplay/android-developer/answer/13609005)."]]