public void launch(String launchPath, String[] args) {
        if (launchPath == null) {
            try {
                launchPath = getRunningPath();
            } catch (UnsupportedEncodingException ex) {
                return;
            }
        }

        ProcessBuilder processBuilder = new ProcessBuilder();
        ArrayList<String> commands = new ArrayList<String>();
        if (!launchPath.endsWith(".exe")) {
            commands.add(OperatingSystem.getJavaDir());
            commands.add("-Xmx256m");
            commands.add("-verbose");
            commands.add("-Djava.net.preferIPv4Stack=true");
            commands.add("-Dawt.useSystemAAFontSettings=lcd");
            commands.add("-Dswing.aatext=true");
            commands.add("-cp");
            commands.add(launchPath);
            commands.add(getMainClass().getName());
        } else
            commands.add(launchPath);
        commands.addAll(Arrays.asList(args));

        String command = "";

        for (String token : commands) {
            command += token + " ";
        }

        Utils.getLogger().info("Launching command: '" + command + "'");

        processBuilder.command(commands);

        try {
            processBuilder.start();
        } catch (IOException ex) {
            JOptionPane.showMessageDialog(null, "Your OS has prevented this relaunch from completing.  You may need to add an exception in your security software.", "Relaunch Failed", JOptionPane.ERROR_MESSAGE);
            ex.printStackTrace();
        } catch (Exception e) {
            e.printStackTrace();
        }
        System.exit(0);
    }