}
String jreHome = System.getProperty("java.home");
File installLocation = new File(jreHome);
final IVMInstallType vmInstallType = JavaRuntime.getVMInstallType(StandardVMType.ID_STANDARD_VM_TYPE);
// find an unused VM id
String id = null;
do {
id = String.valueOf(System.currentTimeMillis());
} while (vmInstallType.findVMInstall(id) != null);
VMStandin newVm = new VMStandin(vmInstallType, id);
newVm.setName("Default-VM");
newVm.setInstallLocation(installLocation);
IVMInstall realVm = newVm.convertToRealVM();