更新时间:2022-06-06 09:01:32
带空格的文件名可以正常工作
File name with space works just fine
这是我的代码
File f = new File("/Windows/F/Programming/Projects/NetBeans/TestApplications/database prop.properties");
System.out.println(f.exists());
try
{
FileInputStream stream = new FileInputStream(f);
}
catch (FileNotFoundException ex)
{
System.out.println(ex.getMessage());
}
f.exists()
始终返回true
毫无问题