码迷,mamicode.com
首页 > 其他好文 > 详细

胡53

时间:2017-05-04 00:03:26      阅读:238      评论:0      收藏:0      [点我收藏+]

标签:rect   path   pat   []   rgs   null   turn   util   getpath   

package com.rjtx;

import java.io.File;
import java.util.Arrays;

public class MainFile {

public static void main(String[] args) {
// TODO Auto-generated method stub

System.out.println("hdw ");
ScanFolder("G:\\2345");
}



public static void ScanFolder(String folder)
{
//int length = folder.length();
File file = new File(folder);
if(null == file)
{
return;
}
File[] fList = file.listFiles();



/*byte[] b = new byte[length];
Arrays.fill(b, (byte)32);
String s = new String(b);
*/

for(int i =0; i< fList.length;i++)
{
String path = fList[i].getPath();
//String fName = fList[i].getName();



System.out.println(path);
if(fList[i].isDirectory())
{
ScanFolder(path);
}
/*
if(fList[i].isDirectory())
{
System.out.println(path);
ScanFolder(path);
}
else
{

System.out.println(pat);
}
*/

}




}

}

胡53

标签:rect   path   pat   []   rgs   null   turn   util   getpath   

原文地址:http://www.cnblogs.com/lingasher/p/6804460.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!