title: DownloadManager getFilesDir()
body: <p>I need to download the file to the internal memory of the device. I do it this way:</p>
  
  <pre><code>Uri downloadUri = Uri.parse(url);
  DownloadManager.Request request = new DownloadManager.Request(downloadUri);
  request.setDestinationInExternalFilesDir(getContext(),getContext().getFilesDir().getAbsolutePath(), name);
  </code></pre>
  
  <p>The file loads successfully. I need to check the presence of this file so I do not have to download it again:</p>
  
  <pre><code>File file = new File(getContext().getFilesDir().getAbsolutePath(), name);
  if (!file.exists()) {
     ...
  }
  </code></pre>
  
  <p>The check does not work, the file always loads again.
  I also try to get a file for MediaPlayer()</p>
  
  <pre><code>String path = "file://" + getContext().getFilesDir().getAbsolutePath() + File.separator + name;
  mMediaPlayer = new MediaPlayer();
  mMediaPlayer.setDataSource(getContext(), Uri.parse(path));
  </code></pre>
  
  <p>This also does not work...
  What am I doing wrong?</p>