The doesFileExist method takes an array of directory names representing a path from the root filesystem and a file name. The method returns true if the file exists,falst if does not.
Place the code fragments in position to complete this method.____________
for(String dir:directories){
____________
}
____________
____________
}所有提供选项:
path=path.getSubdirectory(dir); return !file.isNew();return (file!=null); String path="";path=path.getFile(filename); File path=new File("");return file.exists(); return path is file();File file=new File(path,filename); path=new File(path,dir);File path=new File(File.separator); path=path +File.separator+dir;
Place the code fragments in position to complete this method.____________
for(String dir:directories){
____________
}
____________
____________
}所有提供选项:
path=path.getSubdirectory(dir); return !file.isNew();return (file!=null); String path="";path=path.getFile(filename); File path=new File("");return file.exists(); return path is file();File file=new File(path,filename); path=new File(path,dir);File path=new File(File.separator); path=path +File.separator+dir;
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货