public class TLcdSystemPropertiesUtil extends Object
System
properties.Modifier and Type | Class and Description |
---|---|
static class |
TLcdSystemPropertiesUtil.JavaVersion
Enum of the recognized java versions.
|
Constructor and Description |
---|
TLcdSystemPropertiesUtil() |
Modifier and Type | Method and Description |
---|---|
static boolean |
isJava10()
Deprecated.
use
isJavaVersion(JavaVersion) instead |
static boolean |
isJava11()
Deprecated.
use
isJavaVersion(JavaVersion) instead |
static boolean |
isJava8()
Deprecated.
The minimum JDK requirement is higher than or equal to 1.8, so this method will always return true.
Code using this method to check the version can be simplified.
|
static boolean |
isJava9()
Deprecated.
use
isJavaVersion(JavaVersion) instead |
static boolean |
isJavaVersion(TLcdSystemPropertiesUtil.JavaVersion aJavaVersion)
Check if the Virtual Machine is running with the provided Java version or higher.
|
static boolean |
isLinux()
Returns true if the Virtual Machine is running on a Linux operating system,
false otherwise
|
static boolean |
isMacOS()
Returns true if the Virtual Machine is running on a Mac operating system,
false otherwise
|
static boolean |
isWindows()
Returns true if the Virtual Machine is running on a Windows operating system,
false otherwise
|
static void |
printSystemProperties(PrintStream aPrintStream)
Prints all the system properties to the given PrintStream.
|
public static boolean isWindows()
public static boolean isMacOS()
public static boolean isLinux()
@Deprecated public static boolean isJava8()
@Deprecated public static boolean isJava9()
isJavaVersion(JavaVersion)
instead@Deprecated public static boolean isJava10()
isJavaVersion(JavaVersion)
instead@Deprecated public static boolean isJava11()
isJavaVersion(JavaVersion)
insteadpublic static boolean isJavaVersion(TLcdSystemPropertiesUtil.JavaVersion aJavaVersion)
aJavaVersion
- the java version to check againsttrue
if the Virtual Machine is running with the provided Java version or higher, false
otherwisepublic static void printSystemProperties(PrintStream aPrintStream)
aPrintStream
- the output PrintStream
.