(String original, String modified)
| 6 | public class HttpComparer { |
| 7 | |
| 8 | public static String diffText(String original, String modified) { |
| 9 | if (original.length() > 10000 || modified.length() > 10000) { |
| 10 | return "Input too large, cannot generate diff."; |
| 11 | } else { |
| 12 | diff_match_patch differ = new diff_match_patch(); |
| 13 | LinkedList<diff_match_patch.Diff> diff; |
| 14 | diff = differ.diff_main(original, modified, true); |
| 15 | differ.diff_cleanupSemantic(diff); |
| 16 | return diffToHtml(diff); |
| 17 | } |
| 18 | } |
| 19 | |
| 20 | public static String diffLines(String original, String modified) { |
| 21 | if (original.length() > 20000 || modified.length() > 20000) { |
no test coverage detected