System directories
| Method | Result |
|---|---|
| Environment.getDataDirectory() | /data |
| Environment.getDownloadCacheDirectory() | /cache |
| Environment.getRootDirectory() | /system |
External storage directories
| import android.content.Context; | |
| import android.content.Intent; | |
| import android.support.v4.content.WakefulBroadcastReceiver; | |
| import android.util.Log; | |
| /** | |
| * This is called whenever app receives notification | |
| * in background/foreground state so you can | |
| * apply logic for background task, but still Firebase notification | |
| * will be shown in notification tray |
| buildscript { | |
| repositories { | |
| mavenCentral() | |
| maven { | |
| url 'https://oss.sonatype.org/content/repositories/snapshots/' | |
| } | |
| } | |
| dependencies { | |
| classpath 'com.android.tools.build:gradle:0.9.+' | |
| classpath 'com.squareup.gradle:gradle-android-test-plugin:0.9.1-SNAPSHOT' |
System directories
| Method | Result |
|---|---|
| Environment.getDataDirectory() | /data |
| Environment.getDownloadCacheDirectory() | /cache |
| Environment.getRootDirectory() | /system |
External storage directories