Package nz.ac.waikato.cms.core
Class OS
java.lang.Object
nz.ac.waikato.cms.core.OS
Helper class for operating system related stuff.
- Version:
- $Revision: 10557 $
- Author:
- fracpete (fracpete at waikato dot ac dot nz)
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic intReturns the "bitness", ie 32 or 64 bit of the underlying OS.static booleanChecks whether the operating system is Android.static booleanisLinux()Checks whether the operating system is Linux (but not Android).static booleanisMac()Checks whether the operating system is Windows.static booleanChecks whether the operating system is Windows.
-
Field Details
-
m_IsWindows
whether the OS is Windows. -
m_IsMac
whether the OS is Mac. -
m_IsLinux
whether the OS is Linux. -
m_IsAndroid
whether the OS is Android.
-
-
Constructor Details
-
OS
public OS()
-
-
Method Details
-
isWindows
public static boolean isWindows()Checks whether the operating system is Windows.- Returns:
- true if the OS is Windows flavor
-
isMac
public static boolean isMac()Checks whether the operating system is Windows.- Returns:
- true if the OS is Windows flavor
-
isLinux
public static boolean isLinux()Checks whether the operating system is Linux (but not Android).- Returns:
- true if the OS is Linux flavor (but not Android)
-
isAndroid
public static boolean isAndroid()Checks whether the operating system is Android.- Returns:
- true if the OS is Android flavor
-
getBitness
public static int getBitness()Returns the "bitness", ie 32 or 64 bit of the underlying OS.- Returns:
- the number of bits
-