Comparison of HTML content/Text differences comparison of open source code

Source: Internet
Author: User

1. diffplex-A. Net diff Generator
Http://diffplex.codeplex.com/

Introduction:

Specific use can see http://diffplex.codeplex.com/wikipage? Title = Library & referringtitle = home

Idiffer is the core class of difference comparison, providing a rough comparison of the two texts with low accuracy

Isidebysidediff: provides high-precision comparison and can be used to compare and display the differences in two columns

Interface

Silverlight

 

 Website

 

 

2. diffengine

Introduction:

Powerful functions,

Disadvantage: each line of text cannot exceed 1024 characters

 

Differenceengine. difflist_textfile sourcefile NULL;
Differenceengine. difflist_textfile destinationfile = NULL;

Sourcefile = new differenceengine. difflist_textfile ("1.txt ");
Destinationfile = new differenceengine. difflist_textfile ("2.txt ");

Differenceengine. diffengine engine = new differenceengine. diffengine ();
Engine. processdiff (sourcefile, destinationfile, differenceengine. diffenginelevel. fastimperfect );
Arraylist difflines = engine. diffreport ();
Foreach (differenceengine. diffresultspan span in difflines)
{
Switch (span. Status)
{
Case ifferenceengine. diffresultspanstatus. nochange:
// Not changed
Break;
Case differenceengine. diffresultspanstatus. adddestination:
// Newly added
Break;
Case differenceengine. diffresultspanstatus. deletesource:
// Deleted
Break;
Case differenceengine. diffresultspanstatus. replace:
// Modified
Break;
Default:
// Default
Break;

}

}

Example of getting new content:

 

String STR = (differenceengine. textline) (destinationfile. getbyindex (span. destindex). line;

Http://www.codeproject.com/KB/recipes/diffengine.aspx

 

 

3. htmldiff

Introduction:

Htmldiff was originally a ruby version of the HTML difference comparison algorithm. Later, a friend made a C # version, which is very easy to use and too simple.
C # edition: http://htmldiff.codeplex.com/

RUBY: http://github.com/myobie/htmldiff
Http://www.rohland.co.za/index.php/2009/10/31/csharp-html-diff-algorithm/

 

4. ndiffdiff: a diff implementation for lines and chars in Text File

Introduction:

Provide winform demo

Http://www.codeproject.com/KB/recipes/NBDiffDiff.aspx

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.