public static string GetJavaPath() { RuntimeInfo.GatherInfo(); if (RuntimeInfo.IsWindows) { if (File.Exists("C:\\Program Files\\Java\\jre7\\bin\\java.exe")) { return("C:\\Program Files\\Java\\jre7\\bin\\java.exe"); } else { return("C:\\Program Files (x86)\\Java\\jre7\\bin\\java.exe"); } } else { if (File.Exists("/usr/bin/java")) { return("/usr/bin/java"); } else { return("/bin/java"); } } }
private static string GetNativeArchiveFile() { RuntimeInfo.GatherInfo(); string natives = ""; if (RuntimeInfo.IsWindows) { natives = "windows"; } else if (RuntimeInfo.IsLinux) { natives = "linux"; } else if (RuntimeInfo.IsMacOSX) { natives = "macosx"; } else if (RuntimeInfo.IsSolaris) { natives = "solaris"; } natives += "_natives.jar.lzma"; return(natives); }