import javax.swing.filechooser.*;
//在桌面系统上
String path = FileSystemView
.getFileSystemView()
.getDefaultDirectory()
.getPath();
//在 Android activity 中
String path = this.getApplicationInfo().dataDir;
//在 Android fragment 中
String path = getContext().getApplicationInfo().dataDir;