RxcuiNdcHistoryModel common = new RxcuiNdcHistoryModel(); if (model.getNdc() != null && ndc != null) { if (analysisMode && !model.getNdc().equals(ndc)) { common.setNdc(InfoModel.MULTIPLE_VALUES); } else if (model.getNdc().equals(ndc)) { common.setNdc(ndc); found = true; if (model.getStart() != null && start != null) { if (analysisMode && !model.getStart().equals(start)) { common.setStart(InfoModel.MULTIPLE_VALUES); } else if (model.getStart().equals(start)) { common.setStart(start); found = true; if (model.getEnd() != null && end != null) { if (analysisMode && !model.getEnd().equals(end)) { common.setEnd(InfoModel.MULTIPLE_VALUES); } else if (model.getEnd().equals(end)) { common.setEnd(end); found = true;
RxcuiNdcHistoryModel historyModel = new RxcuiNdcHistoryModel(); String prevNdc = null; String prevVersion = null; historyModel.setNdc(record.ndc); historyModel.setEnd(record.version); historyModel.setStart(prevVersion); historyModels.add(historyModel); historyModel = new RxcuiNdcHistoryModel(); historyModel.setNdc(record.ndc); historyModel.setEnd(record.version); historyModel.setStart(prevVersion); historyModels.add(historyModel);
for (final RxcuiNdcHistoryModel in2 : history) { RxcuiNdcHistoryModel commonIngredient = in.getModelInCommon(in2, analysisMode); if (commonIngredient != null && !common.getHistory().contains(commonIngredient)) {