- 不影响应用程序的性能,只要你的外部存储安装在设备上。
- .apk文件保存于外部存储中,但是所有私人的用户数据,数据库,优化过的.dex文件,和提取的原生代码将会保存到设备内存当中。
- 你应用程序安装的独特的容器是被一个随机生成加密的钥匙加密过,只能够被原始安装此应用程序设备的私钥解密。因此,一个应用程序安装在一张sd卡只为一台设备工作。
- 用户能够通过系统设置移动你应用程序到内部存储中。
-
Services 服务
-
Your running
Service
will be killed and will not be restarted when external storage is remounted. You can, however, register for theACTION_EXTERNAL_APPLICATIONS_AVAILABLE
broadcast Intent, which will notify your application when applications installed on external storage have become available to the system again. At which time, you can restart your Service.
Alarm Services 闹钟提醒服务
-
Your alarms registered with
AlarmManager
will be cancelled. You must manually re-register any alarms when external storage is remounted.
Input Method Engines 输入法引擎
- Your IME will be replaced by the default IME. When external storage is remounted, the user can open system settings to enable your IME again. Live Wallpapers 动态壁纸
- Your running Live Wallpaper will be replaced by the default Live Wallpaper. When external storage is remounted, the user can select your Live Wallpaper again. Live Folders 桌面文件夹
- Your Live Folder will be removed from the home screen. When external storage is remounted, the user can add your Live Folder to the home screen again. App Widgets 小工具
- Your App Widget will be removed from the home screen. When external storage is remounted, your App Widget will not be available for the user to select until the system resets the home application (usually not until a system reboot). Account Managers 账户管理
-
Your accounts created with
AccountManager
will disappear until external storage is remounted.
Sync Adapters 同步
-
Your
AbstractThreadedSyncAdap
and all its sync functionality will not work until external storage is remounted.ter
Device Administrators 设备管理员
-
Your
DeviceAdminReceiver
and all its admin capabilities will be disabled, which can have unforeseeable consequences for the device functionality, which may persist after external storage is remounted.
Broadcast Receivers listening for "boot completed"
-
The system delivers the
ACTION_BOOT_COMPLETED
broadcast before the external storage is mounted to the device. If your application is installed on the external storage, it can never receive this broadcast.
Copy Protection 拷贝保护
- Your application cannot be installed to a device's SD card if it uses Android Market's Copy Protection feature. However, if you use Android Market's Application Licensing instead, your application can be installed to internal or external storage, including SD cards
If your application uses any of the features listed above, you should not allow your application to install on external storage. By default, the system will not allow your application to install on the external storage, so you don't need to worry about your existing applications. However, if you're certain that your application should never be installed on the external storage, then you should make this clear by declaring android:installLocation
with a value of "internalOnly
". Though this does not change the default behavior, it explicitly states that your application should only be installed on the internal storage and serves as a reminder to you and other developers that this decision has been made.
In simple terms, anything that does not use the features listed in the previous section are safe when installed on external storage. Large games are more commonly the types of applications that should allow installation on external storage, because games don't typically provide additional services when inactive. When external storage becomes unavailable and a game process is killed, there should be no visible effect when the storage becomes available again and the user restarts the game (assuming that the game properly saved its state during the normal Activity lifecycle).
If your application requires several megabytes for the APK file, you should carefully consider whether to enable the application to install on the external storage so that users can preserve space on their internal storage.
- 不影响应用程序的性能,只要你的外部存储安装在设备上。
- .apk文件保存于外部存储中,但是所有私人的用户数据,数据库,优化过的.dex文件,和提取的原生代码将会保存到设备内存当中。
- 你应用程序安装的独特的容器是被一个随机生成加密的钥匙加密过,只能够被原始安装此应用程序设备的私钥解密。因此,一个应用程序安装在一张sd卡只为一台设备工作。
- 用户能够通过系统设置移动你应用程序到内部存储中。
-
Services 服务
-
Your running
Service
will be killed and will not be restarted when external storage is remounted. You can, however, register for theACTION_EXTERNAL_APPLICATIONS_AVAILABLE
broadcast Intent, which will notify your application when applications installed on external storage have become available to the system again. At which time, you can restart your Service.
Alarm Services 闹钟提醒服务
-
Your alarms registered with
AlarmManager
will be cancelled. You must manually re-register any alarms when external storage is remounted.
Input Method Engines 输入法引擎
- Your IME will be replaced by the default IME. When external storage is remounted, the user can open system settings to enable your IME again. Live Wallpapers 动态壁纸
- Your running Live Wallpaper will be replaced by the default Live Wallpaper. When external storage is remounted, the user can select your Live Wallpaper again. Live Folders 桌面文件夹
- Your Live Folder will be removed from the home screen. When external storage is remounted, the user can add your Live Folder to the home screen again. App Widgets 小工具
- Your App Widget will be removed from the home screen. When external storage is remounted, your App Widget will not be available for the user to select until the system resets the home application (usually not until a system reboot). Account Managers 账户管理
-
Your accounts created with
AccountManager
will disappear until external storage is remounted.
Sync Adapters 同步
-
Your
AbstractThreadedSyncAdap
and all its sync functionality will not work until external storage is remounted.ter
Device Administrators 设备管理员
-
Your
DeviceAdminReceiver
and all its admin capabilities will be disabled, which can have unforeseeable consequences for the device functionality, which may persist after external storage is remounted.
Broadcast Receivers listening for "boot completed"
-
The system delivers the
ACTION_BOOT_COMPLETED
broadcast before the external storage is mounted to the device. If your application is installed on the external storage, it can never receive this broadcast.
Copy Protection 拷贝保护
- Your application cannot be installed to a device's SD card if it uses Android Market's Copy Protection feature. However, if you use Android Market's Application Licensing instead, your application can be installed to internal or external storage, including SD cards
If your application uses any of the features listed above, you should not allow your application to install on external storage. By default, the system will not allow your application to install on the external storage, so you don't need to worry about your existing applications. However, if you're certain that your application should never be installed on the external storage, then you should make this clear by declaring android:installLocation
with a value of "internalOnly
". Though this does not change the default behavior, it explicitly states that your application should only be installed on the internal storage and serves as a reminder to you and other developers that this decision has been made.
In simple terms, anything that does not use the features listed in the previous section are safe when installed on external storage. Large games are more commonly the types of applications that should allow installation on external storage, because games don't typically provide additional services when inactive. When external storage becomes unavailable and a game process is killed, there should be no visible effect when the storage becomes available again and the user restarts the game (assuming that the game properly saved its state during the normal Activity lifecycle).
If your application requires several megabytes for the APK file, you should carefully consider whether to enable the application to install on the external storage so that users can preserve space on their internal storage.