title: requires android.permission.ACCESS_ALL_DOWNLOADS, or grantUriPermission()
body: <p>When I'm going select a file from all downloads folder and then getting file path from uri using content provider getting following permission denied issue below</p>
  
  <pre><code>Permission Denial: reading com.android.providers.downloads.DownloadProvider uri content://downloads/all_downloads/1092 from pid=31615, uid=10228 requires android.permission.ACCESS_ALL_DOWNLOADS, or grantUriPermission()
  </code></pre>
  
  <p>using following code</p>
  
  <pre><code>String[] contentUriPrefixesToTry = new String[]{
                  "content://downloads/public_downloads",
                  "content://downloads/my_downloads",
                  "content://downloads/all_downloads"
          };
          final String id = DocumentsContract.getDocumentId(uri);
          String path = null;
          for (String uriPath : contentUriPrefixesToTry) {
              final Uri contentUri = ContentUris.withAppendedId(
                      Uri.parse(uriPath), Long.valueOf(id));
              String lastPathSagment = uri.getLastPathSegment();
              InputStream inputStream = context.getContentResolver().openInputStream(uri);
              File file = new File(context.getCacheDir().getAbsolutePath() + "/" + lastPathSagment);
              writeFile(inputStream, file);
              path = file.getAbsolutePath();
               if (path != null) {
               return path;
               }
          }
  </code></pre>