if (host.getPortRangeStart() > 0 && host.getPortRangeEnd() > 0) {
portRangeType.setStart(Integer.valueOf(host.getPortRangeStart()));
portRangeType.setEnd(Integer.valueOf(host.getPortRangeEnd()));
}
PackageType javaInstallation;
if (hostConf.getJavaArray() != null
&& hostConf.getJavaArray().length > 0) {
javaInstallation = hostConf.getJavaArray(0);
} else {
javaInstallation = hostConf.addNewJava();
}
String jdkName = host.getJdkName();
javaInstallation.setName(jdkName);
javaInstallation.setHome(host.getJdkPath());
// FIXME: hostBean should not be needed
javaInstallation.setVersion(jdkName.replaceAll("java", ""));
if (host.getHostEnv() != null) {
HashMap<String, NameValuePairType> envMap = new HashMap<String, NameValuePairType>();
if (hostConf.getHostEnvArray() != null) {
for (NameValuePairType pair : hostConf.getHostEnvArray()) {