isExistの実装を変更

This commit is contained in:
r-ca committed 2024-01-09 13:44:28 +09:00
1 parent b3a4207762
commit a887446d21
2 files changed
+4 -4

No files matched your search

@@ -14,7 +14,7 @@ import java.util.List;
public interface FileManager {
File getFileRef();
boolean isExist();
boolean isExist(String name) throws IOException;
boolean isDirectory();
boolean isFile();
boolean isWritable();
@@ -71,9 +71,9 @@ public class FileManagerImpl implements FileManager {
}
@Override
public boolean isExist() {
File file = this.path.toFile();
return file.exists();
public boolean isExist(String name) throws IOException {
Path resolvedPath = this.resolveStringPath(name);
return Files.exists(resolvedPath);
}
@Override