/** * Adjusts the revision information to the given diff information. Any previous diff information * is discarded. * * @param hunks the diff hunks to adjust the revision information to * @since 3.3 */ final void applyDiff(Hunk[] hunks) { fRanges= null; // mark for recomputation for (ChangeRegion region : fChangeRegions) { region.clearDiff(); for (Hunk hunk : hunks) { region.adjustTo(hunk); } } }
/** * Adjusts the revision information to the given diff information. Any previous diff information * is discarded. * * @param hunks the diff hunks to adjust the revision information to * @since 3.3 */ final void applyDiff(Hunk[] hunks) { fRanges= null; // mark for recomputation for (Iterator<ChangeRegion> regions= fChangeRegions.iterator(); regions.hasNext();) { ChangeRegion region= regions.next(); region.clearDiff(); for (int i= 0; i < hunks.length; i++) { Hunk hunk= hunks[i]; region.adjustTo(hunk); } } }