There are many questions on this topic, but I can not find the answers to my corrective examples.
I use Samsung Galaxy S5 to run Android 4.4, which is limited for storage
The white paper says:
The WRITE_EXTERNAL_STORAGE permission should only provide write access to the primary external storage on the device. Applications are not allowed to write to external external storage devices, with the exception of their directories specific to the package, as allowed by synthesized permissions. Limiting recording in this way ensures that the system can clean up files when applications are uninstalled.
My application should write files to Sdcard (Absolute path is /storage/extSdCard ), so I write my application data to the directory of my application: /storage/extSdCard/Android/com.myapp.example/files , but received an exception that was excluded from permission . Therefore, I suspect the following statement:
excluding their directories specific directories allowed by synthesized permissions
I think that I can not write to the root directory /storage/extSdCard , but still I can write the data of my application to the directory of my application. Am I misunderstood something?
p / s: I can still write my application data to the built-in storage: /storage/emulated/0/Android/data/com.myapp.example/files . I do not want to use getExternalFileDirs() because it always returns the built-in, not my sdcard directory.
android
LuongPham Oct 06 '15 at 4:00 2015-10-06 04:00
source share