Class VersionController

java.lang.Object
com.dianxin.tori.api.controller.VersionController

public final class VersionController extends Object
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 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

      public static String 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.