import java.io.*;
public class FileClass{
String sPath;
String sFilePath;
String sContent;
public boolean newFloder(String s){
sPath = s;
sPath = sPath.toString();
File myFilePath = new File(sPath);
if(!myFilePath.exists()){
myFilePath.mkdirs();
return true;
}
else return false;
}
public static void main(String [] args){
FileClass file1 = new FileClass();
String s = "F:/TEST";
if(file1.newFloder(s)){
System.out.println("文件夹创建成功!");
}
else System.out.println("文件创建失败");
}
}
public class FileClass{
String sPath;
String sFilePath;
String sContent;
public boolean newFloder(String s){
sPath = s;
sPath = sPath.toString();
File myFilePath = new File(sPath);
if(!myFilePath.exists()){
myFilePath.mkdirs();
return true;
}
else return false;
}
public static void main(String [] args){
FileClass file1 = new FileClass();
String s = "F:/TEST";
if(file1.newFloder(s)){
System.out.println("文件夹创建成功!");
}
else System.out.println("文件创建失败");
}
}