/**
* 获取路径
* 遍历手持机所有跟路径,找出可用空间最大的路径作为返回值,
* 并存入RMS,下次启动程序直接从RMS读取路径
*
* @return
*/
public String getPhonePath() {
String phonePath = "";
try {
RecordStore rootPathRms = RecordStore.openRecordStore("phonePath", true);
int num = rootPathRms.getNumRecords();
if (num > 0) {
byte[] b = rootPathRms.getRecord(1);
phonePath = new String(b, "utf-8");
} else if (phonePath.equals("") || phonePath == null) {
String[] roots = new String[10];
Enumeration e = FileSystemRegistry.listRoots();
int i = 0;
while (e.hasMoreElements()) {
String root = (String) e.nextElement();
roots[i] = root;
i++;
}
long[] rootSizes = new long[i];
for (int j = 0; j < i; j++) {
FileConnection fc;