Package com.dianxin.tori.api.controller
Class VersionController
java.lang.Object
com.dianxin.tori.api.controller.VersionController
A utility controller responsible for verifying the runtime environment's compatibility.
This includes validating both the running Java version and the implemented JDA
(Java Discord API) version against the system's minimum requirements.
-
Method Summary
Modifier and TypeMethodDescriptionstatic voidChecks if the currently running Java version meets the minimum required version.static voidChecks if the currently running Java version meets the minimum required version for JDave support.static voidChecks if the currently implemented JDA version meets the minimum required version.static StringRetrieves the version of JDA (Java Discord API) currently implemented at runtime.
-
Method Details
-
checkCompatibilityOrThrow
public static void checkCompatibilityOrThrow()Checks if the currently running Java version meets the minimum required version.- Throws:
UnsupportedOperationException- if the running Java version is lower than the required version.
-
getJdaVersionImplemented
Retrieves the version of JDA (Java Discord API) currently implemented at runtime.- Returns:
- A string representing the runtime JDA version.
-
checkJDACompatibilityOrThrow
public static void checkJDACompatibilityOrThrow()Checks if the currently implemented JDA version meets the minimum required version.- Throws:
UnsupportedOperationException- if the running JDA version is incompatible (lower than required).
-
checkJavaVersionForJDaveOrThrow
public static void checkJavaVersionForJDaveOrThrow()Checks if the currently running Java version meets the minimum required version for JDave support. JDave requires Java 25 or higher for optimal audio encryption performance.- Throws:
UnsupportedOperationException- if the running Java version is lower than Java 25.
-