Skip to content

Commit eabdafd

Browse files
committed
1 parent 6a70054 commit eabdafd

File tree

3 files changed

+4
-17
lines changed

3 files changed

+4
-17
lines changed

src/main/java/difflib/algorithm/myers/DiffNode.java

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -19,19 +19,6 @@
1919
*/
2020
package difflib.algorithm.myers;
2121

22-
/**
23-
* <p>
24-
* Title: </p>
25-
* <p>
26-
* Description: </p>
27-
* <p>
28-
* Copyright: Copyright (c) 2002</p>
29-
* <p>
30-
* Company: </p>
31-
*
32-
* @author not attributable
33-
* @version 1.0
34-
*/
3522
/**
3623
* A diffnode in a diffpath.
3724
* <p>

src/main/java/difflib/algorithm/myers/MyersDiff.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545
* @author <a href="mailto:juanco@suigeneris.org">Juanco Anez</a>
4646
* @param T The type of the compared elements in the 'lines'.
4747
*/
48-
public class MyersDiff<T> implements DiffAlgorithm<T> {
48+
public final class MyersDiff<T> implements DiffAlgorithm<T> {
4949

5050
/**
5151
* Default equalizer.
@@ -117,7 +117,7 @@ public Patch<T> diff(final List<T> original, final List<T> revised) throws DiffE
117117
* @return A minimum {@link PathNode Path} accross the differences graph.
118118
* @throws DifferentiationFailedException if a diff path could not be found.
119119
*/
120-
public PathNode buildPath(final List<T> orig, final List<T> rev)
120+
private PathNode buildPath(final List<T> orig, final List<T> rev)
121121
throws DifferentiationFailedException {
122122
if (orig == null) {
123123
throw new IllegalArgumentException("original sequence is null");
@@ -192,7 +192,7 @@ public PathNode buildPath(final List<T> orig, final List<T> rev)
192192
* @throws DifferentiationFailedException if a {@link Patch} could not be built from the given
193193
* path.
194194
*/
195-
public Patch<T> buildRevision(PathNode path, List<T> orig, List<T> rev) {
195+
private Patch<T> buildRevision(PathNode path, List<T> orig, List<T> rev) {
196196
if (path == null) {
197197
throw new IllegalArgumentException("path is null");
198198
}

src/main/java/difflib/algorithm/myers/PathNode.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ public final PathNode previousSnake() {
9696
*/
9797
@Override
9898
public String toString() {
99-
StringBuffer buf = new StringBuffer("[");
99+
StringBuilder buf = new StringBuilder("[");
100100
PathNode node = this;
101101
while (node != null) {
102102
buf.append("(");

0 commit comments

Comments
 (0)