0
任何人都可以解释为什么此代码不会工作吗?为什么它不在给定的目的地创建文件?相反,它只是输出groupId而不是创建语句。无法在给定列表中的特定文件夹中创建文件
任何帮助或指导将不胜感激。
List<String> groupList = userGroupAuthor.getPredefinedGroupList();
String groupId;
for (String groupName : groupList) {
groupId = StringHelper.makeGroupId(groupName);
System.out.println(groupId);
//writeGroupName(groupId, groupName);
File f = new File(testScriptName);
try{
boolean fvar = f.createNewFile();
if(fvar){
System.out.println("File Created");
}else {
System.out.println("Not Created");
}
}
//bw = new BufferedWriter(new FileWriter(f));
catch (IOException e1) {
// TODO Auto-generated catch block
e1.printStackTrace();
}
}
这与C有什么关系? –