mirror of
https://github.com/java-diff-utils/java-diff-utils.git
synced 2026-03-13 10:11:17 +08:00
moved to new main package com.github
This commit is contained in:
@@ -17,14 +17,14 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib;
|
||||
package com.github.difflib;
|
||||
|
||||
import difflib.algorithm.DiffAlgorithm;
|
||||
import difflib.algorithm.DiffException;
|
||||
import difflib.algorithm.myers.MyersDiff;
|
||||
import difflib.patch.Delta;
|
||||
import difflib.patch.Patch;
|
||||
import difflib.patch.PatchFailedException;
|
||||
import com.github.difflib.algorithm.DiffAlgorithm;
|
||||
import com.github.difflib.algorithm.DiffException;
|
||||
import com.github.difflib.algorithm.myers.MyersDiff;
|
||||
import com.github.difflib.patch.Delta;
|
||||
import com.github.difflib.patch.Patch;
|
||||
import com.github.difflib.patch.PatchFailedException;
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.LinkedList;
|
||||
@@ -13,12 +13,12 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package difflib;
|
||||
package com.github.difflib;
|
||||
|
||||
import difflib.patch.ChangeDelta;
|
||||
import difflib.patch.Chunk;
|
||||
import difflib.patch.Delta;
|
||||
import difflib.patch.Patch;
|
||||
import com.github.difflib.patch.ChangeDelta;
|
||||
import com.github.difflib.patch.Chunk;
|
||||
import com.github.difflib.patch.Delta;
|
||||
import com.github.difflib.patch.Patch;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.regex.Matcher;
|
||||
@@ -13,9 +13,9 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package difflib.algorithm;
|
||||
package com.github.difflib.algorithm;
|
||||
|
||||
import difflib.patch.DeltaType;
|
||||
import com.github.difflib.patch.DeltaType;
|
||||
|
||||
/**
|
||||
*
|
||||
@@ -17,9 +17,9 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib.algorithm;
|
||||
package com.github.difflib.algorithm;
|
||||
|
||||
import difflib.patch.Patch;
|
||||
import com.github.difflib.patch.Patch;
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
@@ -17,7 +17,7 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib.algorithm;
|
||||
package com.github.difflib.algorithm;
|
||||
|
||||
public class DiffException extends Exception {
|
||||
|
||||
@@ -17,9 +17,9 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib.algorithm;
|
||||
package com.github.difflib.algorithm;
|
||||
|
||||
import difflib.algorithm.DiffException;
|
||||
import com.github.difflib.algorithm.DiffException;
|
||||
|
||||
/**
|
||||
* Thrown whenever the differencing engine cannot produce the differences between two revisions of
|
||||
@@ -13,12 +13,12 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package difflib.algorithm.jgit;
|
||||
package com.github.difflib.algorithm.jgit;
|
||||
|
||||
import difflib.algorithm.Change;
|
||||
import difflib.algorithm.DiffAlgorithm;
|
||||
import difflib.algorithm.DiffException;
|
||||
import difflib.patch.DeltaType;
|
||||
import com.github.difflib.algorithm.Change;
|
||||
import com.github.difflib.algorithm.DiffAlgorithm;
|
||||
import com.github.difflib.algorithm.DiffException;
|
||||
import com.github.difflib.patch.DeltaType;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
@@ -17,14 +17,14 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib.algorithm.myers;
|
||||
package com.github.difflib.algorithm.myers;
|
||||
|
||||
import difflib.algorithm.Change;
|
||||
import difflib.algorithm.DifferentiationFailedException;
|
||||
import difflib.algorithm.DiffAlgorithm;
|
||||
import difflib.algorithm.DiffException;
|
||||
import difflib.patch.DeltaType;
|
||||
import difflib.patch.Patch;
|
||||
import com.github.difflib.algorithm.Change;
|
||||
import com.github.difflib.algorithm.DifferentiationFailedException;
|
||||
import com.github.difflib.algorithm.DiffAlgorithm;
|
||||
import com.github.difflib.algorithm.DiffException;
|
||||
import com.github.difflib.patch.DeltaType;
|
||||
import com.github.difflib.patch.Patch;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
@@ -17,7 +17,7 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib.algorithm.myers;
|
||||
package com.github.difflib.algorithm.myers;
|
||||
|
||||
/**
|
||||
* A node in a diffpath.
|
||||
@@ -17,7 +17,7 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib.patch;
|
||||
package com.github.difflib.patch;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@@ -17,7 +17,7 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib.patch;
|
||||
package com.github.difflib.patch;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
@@ -17,7 +17,7 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib.patch;
|
||||
package com.github.difflib.patch;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@@ -17,7 +17,7 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib.patch;
|
||||
package com.github.difflib.patch;
|
||||
|
||||
import java.util.*;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package difflib.patch;
|
||||
package com.github.difflib.patch;
|
||||
|
||||
/**
|
||||
* Specifies the type of the delta.
|
||||
@@ -17,7 +17,7 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib.patch;
|
||||
package com.github.difflib.patch;
|
||||
|
||||
/**
|
||||
* Base class for all exceptions emanating from this package.
|
||||
@@ -17,7 +17,7 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib.patch;
|
||||
package com.github.difflib.patch;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@@ -17,11 +17,11 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib.patch;
|
||||
package com.github.difflib.patch;
|
||||
|
||||
import difflib.algorithm.Change;
|
||||
import static difflib.patch.DeltaType.DELETE;
|
||||
import static difflib.patch.DeltaType.INSERT;
|
||||
import com.github.difflib.algorithm.Change;
|
||||
import static com.github.difflib.patch.DeltaType.DELETE;
|
||||
import static com.github.difflib.patch.DeltaType.INSERT;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
import static java.util.Comparator.comparing;
|
||||
@@ -17,7 +17,7 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib.patch;
|
||||
package com.github.difflib.patch;
|
||||
|
||||
/**
|
||||
* Thrown whenever a delta cannot be applied as a patch to a given text.
|
||||
@@ -17,7 +17,7 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib.text;
|
||||
package com.github.difflib.text;
|
||||
|
||||
/**
|
||||
* Describes the diff row in form [tag, oldLine, newLine) for showing the difference between two
|
||||
@@ -17,17 +17,17 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib.text;
|
||||
package com.github.difflib.text;
|
||||
|
||||
import difflib.DiffUtils;
|
||||
import difflib.algorithm.DiffException;
|
||||
import difflib.patch.ChangeDelta;
|
||||
import difflib.patch.Chunk;
|
||||
import difflib.patch.DeleteDelta;
|
||||
import difflib.patch.Delta;
|
||||
import difflib.patch.InsertDelta;
|
||||
import difflib.patch.Patch;
|
||||
import difflib.text.DiffRow.Tag;
|
||||
import com.github.difflib.DiffUtils;
|
||||
import com.github.difflib.algorithm.DiffException;
|
||||
import com.github.difflib.patch.ChangeDelta;
|
||||
import com.github.difflib.patch.Chunk;
|
||||
import com.github.difflib.patch.DeleteDelta;
|
||||
import com.github.difflib.patch.Delta;
|
||||
import com.github.difflib.patch.InsertDelta;
|
||||
import com.github.difflib.patch.Patch;
|
||||
import com.github.difflib.text.DiffRow.Tag;
|
||||
import java.util.*;
|
||||
import java.util.function.BiPredicate;
|
||||
import java.util.function.Function;
|
||||
@@ -17,7 +17,7 @@ See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
* #L%
|
||||
*/
|
||||
package difflib.text;
|
||||
package com.github.difflib.text;
|
||||
|
||||
import java.util.List;
|
||||
import static java.util.stream.Collectors.toList;
|
||||
@@ -1,12 +1,13 @@
|
||||
package difflib;
|
||||
package com.github.difflib;
|
||||
|
||||
import difflib.algorithm.DiffException;
|
||||
import difflib.patch.ChangeDelta;
|
||||
import difflib.patch.Chunk;
|
||||
import difflib.patch.DeleteDelta;
|
||||
import difflib.patch.Delta;
|
||||
import difflib.patch.InsertDelta;
|
||||
import difflib.patch.Patch;
|
||||
import com.github.difflib.DiffUtils;
|
||||
import com.github.difflib.algorithm.DiffException;
|
||||
import com.github.difflib.patch.ChangeDelta;
|
||||
import com.github.difflib.patch.Chunk;
|
||||
import com.github.difflib.patch.DeleteDelta;
|
||||
import com.github.difflib.patch.Delta;
|
||||
import com.github.difflib.patch.InsertDelta;
|
||||
import com.github.difflib.patch.Patch;
|
||||
import java.io.BufferedReader;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
@@ -1,8 +1,10 @@
|
||||
package difflib;
|
||||
package com.github.difflib;
|
||||
|
||||
import difflib.algorithm.DiffException;
|
||||
import difflib.patch.Patch;
|
||||
import difflib.patch.PatchFailedException;
|
||||
import com.github.difflib.DiffUtils;
|
||||
import com.github.difflib.UnifiedDiffUtils;
|
||||
import com.github.difflib.algorithm.DiffException;
|
||||
import com.github.difflib.patch.Patch;
|
||||
import com.github.difflib.patch.PatchFailedException;
|
||||
import java.io.BufferedReader;
|
||||
import java.io.FileNotFoundException;
|
||||
import java.io.FileReader;
|
||||
@@ -1,4 +1,4 @@
|
||||
package difflib;
|
||||
package com.github.difflib;
|
||||
|
||||
/**
|
||||
* Test constants
|
||||
@@ -13,13 +13,14 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package difflib.algorithm.jgit;
|
||||
package com.github.difflib.algorithm.jgit;
|
||||
|
||||
import static difflib.DiffUtilsTest.readStringListFromInputStream;
|
||||
import difflib.TestConstants;
|
||||
import difflib.algorithm.DiffException;
|
||||
import difflib.patch.Patch;
|
||||
import difflib.patch.PatchFailedException;
|
||||
import com.github.difflib.algorithm.jgit.JGitDiff;
|
||||
import static com.github.difflib.DiffUtilsTest.readStringListFromInputStream;
|
||||
import com.github.difflib.TestConstants;
|
||||
import com.github.difflib.algorithm.DiffException;
|
||||
import com.github.difflib.patch.Patch;
|
||||
import com.github.difflib.patch.PatchFailedException;
|
||||
import java.io.IOException;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
@@ -13,13 +13,14 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package difflib.algorithm.jgit;
|
||||
package com.github.difflib.algorithm.jgit;
|
||||
|
||||
import static difflib.DiffUtilsTest.readStringListFromInputStream;
|
||||
import difflib.TestConstants;
|
||||
import difflib.algorithm.DiffException;
|
||||
import difflib.patch.Patch;
|
||||
import difflib.patch.PatchFailedException;
|
||||
import com.github.difflib.algorithm.jgit.JGitDiff;
|
||||
import static com.github.difflib.DiffUtilsTest.readStringListFromInputStream;
|
||||
import com.github.difflib.TestConstants;
|
||||
import com.github.difflib.algorithm.DiffException;
|
||||
import com.github.difflib.patch.Patch;
|
||||
import com.github.difflib.patch.PatchFailedException;
|
||||
import java.io.IOException;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
@@ -13,11 +13,12 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package difflib.algorithm.myers;
|
||||
package com.github.difflib.algorithm.myers;
|
||||
|
||||
import difflib.DiffUtils;
|
||||
import difflib.algorithm.DiffException;
|
||||
import difflib.patch.Patch;
|
||||
import com.github.difflib.algorithm.myers.MyersDiff;
|
||||
import com.github.difflib.DiffUtils;
|
||||
import com.github.difflib.algorithm.DiffException;
|
||||
import com.github.difflib.patch.Patch;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import org.junit.After;
|
||||
@@ -1,10 +1,10 @@
|
||||
package difflib.examples;
|
||||
package com.github.difflib.examples;
|
||||
|
||||
import difflib.DiffUtils;
|
||||
import difflib.TestConstants;
|
||||
import difflib.UnifiedDiffUtils;
|
||||
import difflib.patch.Patch;
|
||||
import difflib.patch.PatchFailedException;
|
||||
import com.github.difflib.DiffUtils;
|
||||
import com.github.difflib.TestConstants;
|
||||
import com.github.difflib.UnifiedDiffUtils;
|
||||
import com.github.difflib.patch.Patch;
|
||||
import com.github.difflib.patch.PatchFailedException;
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.nio.file.Files;
|
||||
@@ -1,10 +1,10 @@
|
||||
package difflib.examples;
|
||||
package com.github.difflib.examples;
|
||||
|
||||
import difflib.DiffUtils;
|
||||
import difflib.TestConstants;
|
||||
import difflib.algorithm.DiffException;
|
||||
import difflib.patch.Delta;
|
||||
import difflib.patch.Patch;
|
||||
import com.github.difflib.DiffUtils;
|
||||
import com.github.difflib.TestConstants;
|
||||
import com.github.difflib.algorithm.DiffException;
|
||||
import com.github.difflib.patch.Delta;
|
||||
import com.github.difflib.patch.Patch;
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.nio.file.Files;
|
||||
@@ -1,7 +1,9 @@
|
||||
package difflib.patch;
|
||||
package com.github.difflib.patch;
|
||||
|
||||
import difflib.DiffUtils;
|
||||
import difflib.algorithm.DiffException;
|
||||
import com.github.difflib.patch.Patch;
|
||||
import com.github.difflib.patch.PatchFailedException;
|
||||
import com.github.difflib.DiffUtils;
|
||||
import com.github.difflib.algorithm.DiffException;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import static org.junit.Assert.assertEquals;
|
||||
@@ -1,6 +1,8 @@
|
||||
package difflib.text;
|
||||
package com.github.difflib.text;
|
||||
|
||||
import difflib.algorithm.DiffException;
|
||||
import com.github.difflib.text.DiffRow;
|
||||
import com.github.difflib.text.DiffRowGenerator;
|
||||
import com.github.difflib.algorithm.DiffException;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import static org.junit.Assert.assertEquals;
|
||||
@@ -13,8 +13,9 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package difflib.text;
|
||||
package com.github.difflib.text;
|
||||
|
||||
import com.github.difflib.text.StringUtils;
|
||||
import java.util.Collections;
|
||||
import org.junit.Test;
|
||||
import static org.junit.Assert.*;
|
||||
Reference in New Issue
Block a user