nn.pp.core

## Class JVMVersionInfo

- java.lang.Object
- - nn.pp.core.JVMVersionInfo

-     public class JVMVersionInfo
      extends java.lang.Object

  Helper class to determine Java runtime versions

- - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static JVMVersionInfo` | `getJVMVersionInfo()` Get an instance of the Java version helper class
    `int` | `getMajorVersion()` Get the major version of this Java version information
    `int` | `getMinorBuildVersion()` Get the build number of this Java version information
    `int` | `getMinorVersion()` Get the minor version of this Java version information
    `int` | `getSubminorVersion()` Get the sub-minor version of this Java version information
    `static java.util.Map<java.lang.String,java.lang.String>` | `getSystemProperties()` Get all important system properties
    `boolean` | `isAtLeast(JVMVersionInfo other)` Compare to another Java version and return whether this instance is at the same or newer version
    `boolean` | `isAtLeast(java.lang.String version)` Compare to another Java version and return whether this instance is at the same or newer version
    `boolean` | `isJava_1_2()` Returns whether the Java version is 1.2 or above (Note: 1.2 not 12!)
    `boolean` | `isJava_1_3()` Returns whether the Java version is 1.3 or above (Note: 1.3 not 13!)
    `boolean` | `isJava_1_4()` Returns whether the Java version is 1.4 or above (Note: 1.4 not 14!)
    `boolean` | `isJava_1_5()` Returns whether the Java version is 1.5 or above (Note: 1.5 not 15!)
    `boolean` | `isJava_1_6()` Returns whether the Java version is 1.6 or above (Note: 1.6 not 16!)
    `boolean` | `isJava_1_7()` Returns whether the Java version is 1.7 or above (Note: 1.7 not 17!)
    `boolean` | `isJava_1_8()` Returns whether the Java version is 1.8 or above (Note: 1.8 not 18!)
    `boolean` | `isJava_9()` Returns whether the Java version is 9 or above
    `boolean` | `isMSJava()` Returns whether the Java VM is from Microsoft
    `boolean` | `isNSJava()` Returns whether the Java VM is from Netscape
    `boolean` | `isPJava()` Returns whether the Java VM is PJava (PersonalJava)
    `java.lang.String` | `toString()` Get the string representation

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Method Detail

    - #### getJVMVersionInfo

          public static JVMVersionInfo getJVMVersionInfo()

      Get an instance of the Java version helper class
      Returns:
        an instance of the Java version helper class

    - #### isJava_1_2

          public boolean isJava_1_2()

      Returns whether the Java version is 1.2 or above (Note: 1.2 not 12!)
      Returns:
        true if the Java version is 1.2 or above, false otherwise

    - #### isJava_1_3

          public boolean isJava_1_3()

      Returns whether the Java version is 1.3 or above (Note: 1.3 not 13!)
      Returns:
        true if the Java version is 1.3 or above, false otherwise

    - #### isJava_1_4

          public boolean isJava_1_4()

      Returns whether the Java version is 1.4 or above (Note: 1.4 not 14!)
      Returns:
        true if the Java version is 1.4 or above, false otherwise

    - #### isJava_1_5

          public boolean isJava_1_5()

      Returns whether the Java version is 1.5 or above (Note: 1.5 not 15!)
      Returns:
        true if the Java version is 1.5 or above, false otherwise

    - #### isJava_1_6

          public boolean isJava_1_6()

      Returns whether the Java version is 1.6 or above (Note: 1.6 not 16!)
      Returns:
        true if the Java version is 1.6 or above, false otherwise

    - #### isJava_1_7

          public boolean isJava_1_7()

      Returns whether the Java version is 1.7 or above (Note: 1.7 not 17!)
      Returns:
        true if the Java version is 1.7 or above, false otherwise

    - #### isJava_1_8

          public boolean isJava_1_8()

      Returns whether the Java version is 1.8 or above (Note: 1.8 not 18!)
      Returns:
        true if the Java version is 1.8 or above, false otherwise

    - #### isJava_9

          public boolean isJava_9()

      Returns whether the Java version is 9 or above
      Returns:
        true if the Java version is 9 or above, false otherwise

    - #### isPJava

          public boolean isPJava()

      Returns whether the Java VM is PJava (PersonalJava)
      Returns:
        true if the Java VM is PJava, false otherwise

    - #### isNSJava

          public boolean isNSJava()

      Returns whether the Java VM is from Netscape
      Returns:
        true if the Java VM is from Netscape, false otherwise

    - #### isMSJava

          public boolean isMSJava()

      Returns whether the Java VM is from Microsoft
      Returns:
        true if the Java VM is from Microsoft, false otherwise

    - #### isAtLeast

          public boolean isAtLeast(JVMVersionInfo other)

      Compare to another Java version and return whether this instance is at the same or newer version
      Parameters:
        `other` - the other Java version information to compare to
      Returns:
        true if this instance is newer or equal to the other version info, false otherwise

    - #### isAtLeast

          public boolean isAtLeast(java.lang.String version)

      Compare to another Java version and return whether this instance is at the same or newer version
      Parameters:
        `version` - the other Java version information (as string) to compare to
      Returns:
        true if this instance is newer or equal to the other version info, false otherwise

    - #### getMajorVersion

          public int getMajorVersion()

      Get the major version of this Java version information
      Returns:
        the major version of this Java version information

    - #### getMinorVersion

          public int getMinorVersion()

      Get the minor version of this Java version information
      Returns:
        the minor version of this Java version information

    - #### getSubminorVersion

          public int getSubminorVersion()

      Get the sub-minor version of this Java version information
      Returns:
        the sub-minor version of this Java version information

    - #### getMinorBuildVersion

          public int getMinorBuildVersion()

      Get the build number of this Java version information
      Returns:
        the build number of this Java version information

    - #### getSystemProperties

          public static java.util.Map<java.lang.String,java.lang.String> getSystemProperties()

      Get all important system properties
      Returns:
        all important system properties

    - #### toString

          public java.lang.String toString()

      Get the string representation
      Overrides:
        `toString` in class `java.lang.Object`
      Returns:
        the string representation

Copyright © 2025 Raritan Inc. All Rights Reserved.