Method
createFile
(Path path, boolean replace)
Source from the content-addressed store, hash-verified
| 139 | } |
| 140 | |
| 141 | public static Path createFile(Path path, boolean replace) throws IOException { |
| 142 | if (replace) { |
| 143 | rmr(path); |
| 144 | return Files.createFile(path); |
| 145 | } else { |
| 146 | if (isExists(path)) { |
| 147 | return path; |
| 148 | } else { |
| 149 | return Files.createFile(path); |
| 150 | } |
| 151 | } |
| 152 | } |
| 153 | |
| 154 | public static Path move(Path src, Path dest, boolean replace) throws IOException { |
| 155 | dest = getPath(dest.toString(), src.getFileName().toString()); |
Callers
nothing calls this directly
Tested by
no test coverage detected