Here you can find the source of getJvmDll(String javahome)
public static String getJvmDll(String javahome)
//package com.java2s; //it under the terms of the GNU Affero General Public License as published by import java.io.File; public class Main { public static String getJvmDll(String javahome) { boolean isJDK = false; File rtJar = new File(javahome, "jre/lib/rt.jar"); if (rtJar.exists()) { isJDK = new File(javahome, "lib/tools.jar").exists(); } else {//w w w. j av a 2s.co m rtJar = new File(javahome, "lib/rt.jar"); } File jrebase = new File(javahome); if (isJDK) { jrebase = new File(jrebase, "jre"); } File jvmdll = new File(jrebase, "bin/server/jvm.dll"); if (!jvmdll.exists()) { jvmdll = new File(jrebase, "bin/client/jvm.dll"); } if (!jvmdll.exists()) { return "auto"; } else { return jvmdll.getAbsolutePath(); } } }