Forget the Storage Permission: Alternatives for sharing and collaborating (Big Android BBQ 2015)

By: Android Developers

162   39   17319

Uploaded on 10/24/2015

Don't use the sledgehammer of the Storage permissions when there's a better way. Learn how FileProvider, GET_CONTENT, and the Storage Access Framework can help you share and collaborate on content across apps without unnecessary permissions.

Ian Lake is a developer advocate focused on the Android framework and the Android Support Library, although you'll always find him with at least a few wearable devices on. Prior to Google, he worked as an Android developer at Facebook and Phunware. Ian received his Masters in Computer Science from the University of Southern California and a Bachelors of Science in Computer Science and a Bachelors of Science in Physics from Montana State University.

Check out the slides from Ian's talk here:

Watch more videos from #BABBQ15:

Subscribe to the Android Developers Channel:

#sharing #storage

Comments (4):

By anonymous    2017-09-20

Per the Forget the Storage Permission talk, getFilesDir() is indeed the right location for private storage of user data.

Original Thread

By anonymous    2017-09-20

That's achievable with Intent#setClipData(ClipData) API.

You can see example usage from Ian Lake's talk "Forget the Storage Permission: Alternatives for sharing and collaborating" talk at Big Android BBQ.

enter image description here A slide from the abovementioned talk.

An example usage:

// Adding into `Intent`
ClipData clipData = ClipData.newRawUri(null, contentUri);
clipData.addItem(new ClipData.Item(secondContentUri));

// Retrieving from `Intent`
ClipData clipData = intent.getClipData();
for (int i = 0, count = clipData.getItemCount(); i < count; ++i) {
    ClipData.Item item = clipData.getItemAt(i);
    Uri uri = item.getUri();

Original Thread

Popular Videos 15

Cloud Native Computing Foundation - CNCF

Submit Your Video

If you have some great dev videos to share, please fill out this form.