+ doublyConstrainedResourceSize + ") should always be 0.");
}
List<LocalResource> localResourceList = new ArrayList<LocalResource>(
globalResourceListSize + renewableLocalResourceSize + nonrenewableLocalResourceSize);
for (int i = 0; i < renewableLocalResourceSize; i++) {
LocalResource localResource = new LocalResource();
localResource.setId(resourceId);
localResource.setProject(project);
localResource.setRenewable(true);
resourceId++;
localResourceList.add(localResource);
}
for (int i = 0; i < nonrenewableLocalResourceSize; i++) {
LocalResource localResource = new LocalResource();
localResource.setId(resourceId);
localResource.setProject(project);
localResource.setRenewable(false);
resourceId++;
localResourceList.add(localResource);
}
project.setLocalResourceList(localResourceList);
schedule.getResourceList().addAll(localResourceList);