LibreOffice Module xmerge (master) 1
|
A very simple and direct difference algorithm for row Node
objects in a spreadsheet.
More...
Public Member Functions | |
Difference[] | computeDiffs (Iterator orgSeq, Iterator modSeq) |
Compute the differences of the given two sequences. More... | |
Difference[] | computeDiffs (Iterator orgSeq, Iterator modSeq) |
Returns a Difference array. More... | |
Private Member Functions | |
Element | splitRepeatedRow (Element orgRow, int splitNum, int orgNum) |
A very simple and direct difference algorithm for row Node
objects in a spreadsheet.
Basically, it will compare objects in sequence and does not look ahead (unlike LCS).
NOTE: The algorithm will have potential side effect to split rows.
Definition at line 61 of file IteratorRowCompare.java.
|
inline |
Compute the differences of the given two sequences.
Refer to the class description.
Return an array of Difference
objects. This method finds out the difference between two sequences.
orgSeq | The original sequence. |
modSeq | The modified (or changed) sequence to compare against with the original. |
Implements org.openoffice.xmerge.merger.DiffAlgorithm.
Definition at line 77 of file IteratorRowCompare.java.
References org.openoffice.xmerge.merger.Difference.ADD, org.openoffice.xmerge.converter.xml.OfficeConstants.ATTRIBUTE_TABLE_NUM_ROWS_REPEATED, org.openoffice.xmerge.merger.Difference.CHANGE, org.openoffice.xmerge.merger.Difference.DELETE, org.openoffice.xmerge.merger.Iterator.equivalent(), i, Integer, org.openoffice.xmerge.merger.Iterator.next(), Object, org.openoffice.xmerge.merger.Iterator.refresh(), org.openoffice.xmerge.merger.diff.IteratorRowCompare.splitRepeatedRow(), org.openoffice.xmerge.merger.Iterator.start(), and String.
|
inlineprivate |
Definition at line 199 of file IteratorRowCompare.java.
References org.openoffice.xmerge.converter.xml.OfficeConstants.ATTRIBUTE_TABLE_NUM_ROWS_REPEATED, and String.
Referenced by org.openoffice.xmerge.merger.diff.IteratorRowCompare.computeDiffs().