Package net.pl3x.map.core.util
Class FileUtil
java.lang.Object
net.pl3x.map.core.util.FileUtil
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidatomicMove(Path source, Path target) static voidcreateDirs(@NotNull Path dirPath) static voiddeleteDirectory(@NotNull Path dir) static voidextractDir(@NotNull String sourceDir, @NotNull Path outDir, boolean replace) static voidextractFile(@NotNull Class<?> clazz, @NotNull String filename, @NotNull Path outDir, boolean replace) static @NotNull Pathstatic @NotNull Pathstatic @NotNull Pathstatic Stringstatic voidreadGzip(@NotNull Path file, @NotNull ByteBuffer buffer) static @NotNull Collection<@NotNull Point>regionPathsToPoints(@NotNull World world, @Nullable Collection<@NotNull Path> paths, boolean ignoreTimestamp) static voidstatic voidstatic Pathstatic void
-
Constructor Details
-
FileUtil
public FileUtil()
-
-
Method Details
-
getTilesDir
-
getWebDir
-
extractFile
-
extractDir
-
writeJson
-
saveGzip
public static void saveGzip(@NotNull @NotNull String json, @NotNull @NotNull Path file) throws IOException - Throws:
IOException
-
saveGzip
- Throws:
IOException
-
readGzip
public static void readGzip(@NotNull @NotNull Path file, @NotNull @NotNull ByteBuffer buffer) throws IOException - Throws:
IOException
-
readGzip
- Throws:
IOException
-
tmp
-
atomicMove
- Throws:
IOException
-
mkDirs
- Throws:
IOException
-
createDirs
-
deleteDirectory
- Throws:
IOException
-
regionPathsToPoints
@NotNull public static @NotNull Collection<@NotNull Point> regionPathsToPoints(@NotNull @NotNull World world, @Nullable @Nullable Collection<@NotNull Path> paths, boolean ignoreTimestamp)
-