private void computeRemedyDetails(Remedy remedy) {
    ArrayList<String> updateIds = new ArrayList<String>();
    for (IInstallableUnit addedIU : remedy.getRequest().getAdditions()) {
      for (IInstallableUnit removedIU : remedy.getRequest().getRemovals()) {
        if (removedIU.getId().equals(addedIU.getId())) {
          createModificationRemedyDetail(addedIU, removedIU, remedy);
          updateIds.add(addedIU.getId());
          break;
        }
      }
      if (!updateIds.contains(addedIU.getId())) {
        createAdditionRemedyDetail(addedIU, remedy);
      }
    }

    for (IInstallableUnit removedIU : remedy.getRequest().getRemovals()) {
      if (!updateIds.contains(removedIU.getId())) {
        createRemovalRemedyDetail(removedIU, remedy);
      }
    }

    for (IInstallableUnit addedIUinOriginalRequest : originalRequest.getAdditions()) {
      boolean found = false;
      for (IInstallableUnit addedIU : remedy.getRequest().getAdditions()) {
        if (addedIU.getId().equals(addedIUinOriginalRequest.getId())) {
          found = true;
          break;
        }
      }
      if (!found) {
        createNotAddedRemedyDetail(addedIUinOriginalRequest, remedy);
        found = false;
      }
    }
  }
 private Version searchInOriginalRequest(String id) {
   for (IInstallableUnit iu : originalRequest.getAdditions()) {
     if (iu.getId() == id) return iu.getVersion();
   }
   return null;
 }