From d88c9c2030c7453670ad5f61c7d292f87a5b4981 Mon Sep 17 00:00:00 2001 From: r-ca Date: Tue, 9 Jan 2024 13:50:47 +0900 Subject: [PATCH] =?UTF-8?q?isExist=E3=82=92=E5=BC=95=E6=95=B0=E3=81=AA?= =?UTF-8?q?=E3=81=97=E3=81=A7=E3=82=82=E5=AE=9F=E8=A1=8C=E3=81=A7=E3=81=8D?= =?UTF-8?q?=E3=82=8B=E3=82=88=E3=81=86=E3=81=AB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/one/nem/lacerta/source/file/FileManager.java | 1 + .../one/nem/lacerta/source/file/impl/FileManagerImpl.java | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/source/src/main/java/one/nem/lacerta/source/file/FileManager.java b/source/src/main/java/one/nem/lacerta/source/file/FileManager.java index f996e781..75eba626 100644 --- a/source/src/main/java/one/nem/lacerta/source/file/FileManager.java +++ b/source/src/main/java/one/nem/lacerta/source/file/FileManager.java @@ -16,6 +16,7 @@ public interface FileManager { File getFileRef(); boolean isExist(String name) throws IOException; + boolean isExist() throws IOException; boolean isDirectory(); boolean isFile(); boolean isWritable(); diff --git a/source/src/main/java/one/nem/lacerta/source/file/impl/FileManagerImpl.java b/source/src/main/java/one/nem/lacerta/source/file/impl/FileManagerImpl.java index 71826eb2..aad29ce1 100644 --- a/source/src/main/java/one/nem/lacerta/source/file/impl/FileManagerImpl.java +++ b/source/src/main/java/one/nem/lacerta/source/file/impl/FileManagerImpl.java @@ -76,6 +76,11 @@ public class FileManagerImpl implements FileManager { return Files.exists(resolvedPath); } + @Override + public boolean isExist() throws IOException { + return Files.exists(this.path); + } + @Override public boolean isDirectory() { if (this.isExist()) {