title: Environment.getExternalStorageDirectory() deprecation alternatives
body: <p>In SDK 29 (Aka Android_Q), The access to external storage using the method <code>Environment.getExternalStorageDirectory()</code> is deprecated and no longer returns an accessible file.</p>
  <blockquote>
  <p>getExtenalStoragePublicDirectory(String type)</p>
  <blockquote>
  <p>This method was deprecated in API level 29. To improve user privacy,direct access to shared/external storage devices is deprecated. When an app targets Build.VERSION_CODES.Q, the path returned from this method is no longer directly accessible to apps. Apps can continue to access content stored on shared/external storage by migrating to alternatives such as Context#getExternalFilesDir(String), MediaStore, or Intent#ACTION_OPEN_DOCUMENT.</p>
  </blockquote>
  </blockquote>
  <p>But using <code>Context#getExternalFilesDir(String)</code> returns a folder inside your App-Data folder. Which is deleted on your app's uninstallation or data clearing.</p>
  <p>But consider how app likes WhatsApp or Facebook Messenger save their backups and downloads, they use external storage and create their custom folders to store their data.</p>
  <p>How will such apps migrate? Is there a new way?</p>
  <p>My app is a notes application that backs-up all the notes into a folder for later restoration after app deletion or data clearing. In SDK 29, I can no longer follow such a method.</p>