ifNotExist実装

This commit is contained in:
r-ca 2024-01-09 13:52:00 +09:00
parent 022e7e278a
commit fbde892f40
No known key found for this signature in database
GPG Key ID: 6A72911AC73464A9

View File

@ -210,12 +210,16 @@ public class FileManagerImpl implements FileManager {
@Override @Override
public FileManager createDirectoryIfNotExist() throws IOException { public FileManager createDirectoryIfNotExist() throws IOException {
return null; if (!this.isExist()) {
this.createDirectory();
}
return this;
} }
@Override @Override
public FileManager createDirectoryIfNotExist(String directoryName) throws IOException { public FileManager createDirectoryIfNotExist(String directoryName) throws IOException {
return null; this.resolve(directoryName);
return this.createDirectoryIfNotExist();
} }
// Internal // Internal