This is useful if you need to verify the environment for legacy software compatibility.
private static boolean check32BitWindows() String osName = System.getProperty("os.name").toLowerCase(); String osArch = System.getProperty("os.arch").toLowerCase(); // "os.arch" on 32-bit Windows can be: x86, i386, i586, i686 boolean is32BitArch = osArch.contains("x86") && !osArch.contains("64"); boolean isWindows = osName.contains("win"); return isWindows && is32BitArch; jdk-7u80-nb-8-0-2-windows-i586.exe windows x86 -32-bit-
import java.io.File; import java.util.regex.Pattern; public class LegacyEnvChecker This is useful if you need to verify