private static List<JvmInstallation> getJvms() {
if (jvms == null) {
FileCanonicalizer fileCanonicalizer = NativeServices.getInstance().get(FileCanonicalizer.class);
jvms = new ArrayList<JvmInstallation>();
jvms.addAll(new DevInfrastructureJvmLocator(fileCanonicalizer).findJvms());
jvms.addAll(new InstalledJvmLocator().findJvms());
jvms.addAll(new HomeDirJvmLocator(fileCanonicalizer).findJvms());
// Order from most recent to least recent
Collections.sort(jvms, new Comparator<JvmInstallation>() {
public int compare(JvmInstallation o1, JvmInstallation o2) {
return o2.getVersion().compareTo(o1.getVersion());