mirror of
https://github.com/FalsePattern/FalsePatternLib.git
synced 2026-11-16 08:24:50 +00:00
Deprecate the StableAPI annotations, switch to JB annotations
This commit is contained in:
96 files changed
+1079
-762
No files matched your search
@@ -21,7 +21,6 @@
|
||||
*/
|
||||
package com.falsepattern.lib.util;
|
||||
|
||||
import com.falsepattern.lib.StableAPI;
|
||||
import lombok.experimental.UtilityClass;
|
||||
|
||||
import net.minecraft.launchwrapper.Launch;
|
||||
@@ -30,15 +29,18 @@ import java.io.File;
|
||||
import java.nio.file.Path;
|
||||
import java.nio.file.Paths;
|
||||
|
||||
/**
|
||||
* @since 0.8.2
|
||||
*/
|
||||
@UtilityClass
|
||||
@StableAPI(since = "0.8.2")
|
||||
public final class FileUtil {
|
||||
@StableAPI.Expose
|
||||
public static File getMinecraftHome() {
|
||||
return getMinecraftHomePath().toFile();
|
||||
}
|
||||
|
||||
@StableAPI.Expose(since = "1.0.0")
|
||||
/**
|
||||
* @since 1.0.0
|
||||
*/
|
||||
public static Path getMinecraftHomePath() {
|
||||
return Launch.minecraftHome == null ? Paths.get("").toAbsolutePath() : Launch.minecraftHome.toPath();
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user