Package com.pnfsoftware.jeb.util.base
Class SystemUtil
java.lang.Object
com.pnfsoftware.jeb.util.base.SystemUtil
Convenient variables and methods to retrieve OS and running JVM information.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String
Java specification version stringstatic final String
Java vendorstatic final String
Java version stringstatic final String
Bitness of the currently executing JRE (this is not the OS bitness!)static final String
Operating system namestatic final String
Operating system version string -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
javavendor
Java vendor -
javaversion
Java version string -
javaspecversion
Java specification version string -
osname
Operating system name -
osarch
Bitness of the currently executing JRE (this is not the OS bitness!) -
osversion
Operating system version string
-
-
Constructor Details
-
SystemUtil
public SystemUtil()
-
-
Method Details
-
getJavaVendor
-
getJavaVersion
-
getJavaSpecificationVersion
-
getOsName
-
getOsArchitecture
- Returns:
- the bitness of the currently executing JRE (this is not the OS bitness!)
-
getOsVersion
-
getMajorJavaVersion
public static int getMajorJavaVersion()Extract the major number from the Java VM executing the method.- Returns:
- the major version, 0 on error
-
parseMajorJavaVersion
Extract the major number from a standard Java version string.- Parameters:
s
- version string- Returns:
- the major version, 0 on error
-