EnvironmentCompat.java
1006 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
package android.support.v4.os;
import android.os.Build.VERSION;
import android.os.Environment;
import android.util.Log;
import java.io.File;
import java.io.IOException;
public final class EnvironmentCompat
{
public static final String MEDIA_UNKNOWN = "unknown";
public static String getStorageState(File paramFile)
{
if (Build.VERSION.SDK_INT >= 19) {
return Environment.getStorageState(paramFile);
}
try
{
if (paramFile.getCanonicalPath().startsWith(Environment.getExternalStorageDirectory().getCanonicalPath()))
{
paramFile = Environment.getExternalStorageState();
return paramFile;
}
}
catch (IOException paramFile)
{
Log.w("EnvironmentCompat", "Failed to resolve canonical path: " + paramFile);
}
return "unknown";
}
}
/* Location: /home/merong/decompile/hackery-dex2jar.jar!/android/support/v4/os/EnvironmentCompat.class
* Java compiler version: 6 (50.0)
* JD-Core Version: 0.7.1
*/