@Test public void overwriteJudgment_Keywords() { JudgmentKeyword keywordABC = new JudgmentKeyword(CourtType.COMMON, "ABC"); JudgmentKeyword keywordDEF = new JudgmentKeyword(CourtType.COMMON, "DEF"); JudgmentKeyword keywordGHI = new JudgmentKeyword(CourtType.COMMON, "GHI"); oldJudgment.addKeyword(keywordABC); oldJudgment.addKeyword(keywordDEF); newJudgment.addKeyword(keywordABC); newJudgment.addKeyword(keywordGHI); ccJudgmentOverwriter.overwriteJudgment(oldJudgment, newJudgment, correctionList); assertThat(newJudgment.getKeywords(), Matchers.containsInAnyOrder(keywordABC, keywordGHI)); assertThat(oldJudgment.getKeywords(), Matchers.containsInAnyOrder(keywordABC, keywordGHI)); }
@Override public void overwriteJudgment(CommonCourtJudgment oldJudgment, CommonCourtJudgment newJudgment, ImportCorrectionList correctionList) { overwriteCourt(oldJudgment, newJudgment); overwriteKeywords(oldJudgment, newJudgment); }
CcSpecificJudgmentOverwriter implements JudgmentOverwriter<CommonCourtJudgment> { @Override public void overwriteJudgment(CommonCourtJudgment oldJudgment, CommonCourtJudgment newJudgment, ImportCorrectionList correctionList) { overwriteCourt(oldJudgment, newJudgment); overwriteKeywords(oldJudgment, newJudgment); } }
CcSpecificJudgmentOverwriter implements JudgmentOverwriter<CommonCourtJudgment> { @Override public void overwriteJudgment(CommonCourtJudgment oldJudgment, CommonCourtJudgment newJudgment, ImportCorrectionList correctionList) { overwriteCourt(oldJudgment, newJudgment); overwriteKeywords(oldJudgment, newJudgment); }  }
CcSpecificJudgmentOverwriter implements JudgmentOverwriter<CommonCourtJudgment> { @Override public void overwriteJudgment(CommonCourtJudgment oldJudgment, CommonCourtJudgment newJudgment, ImportCorrectionList correctionList) { overwriteCourt(oldJudgment, newJudgment); overwriteKeywords(oldJudgment, newJudgment); }  @Override void overwriteJudgment(CommonCourtJudgment oldJudgment, CommonCourtJudgment newJudgment, ImportCorrectionList correctionList); }
CcSpecificJudgmentOverwriter implements JudgmentOverwriter<CommonCourtJudgment> { @Override public void overwriteJudgment(CommonCourtJudgment oldJudgment, CommonCourtJudgment newJudgment, ImportCorrectionList correctionList) { overwriteCourt(oldJudgment, newJudgment); overwriteKeywords(oldJudgment, newJudgment); }  @Override void overwriteJudgment(CommonCourtJudgment oldJudgment, CommonCourtJudgment newJudgment, ImportCorrectionList correctionList);  }