Reversible string differentiation (history) algorithms for C #?

Here is an interesting question that I know little about existing solutions or research in this area, although I would suggest that it relates to the field of compression.

Given the two potentially large lines of text, where one is a later version of the first, is it possible (I know it is possible, I really ask if there are existing solutions) to compare these two lines and reduce them to a set of differences, which can then be used for deterministic reconstruction of source strings?

In my case, I am interested in saving the latest version of the string, but keeping "compressed" (various) historical backups that can be restored as needed without actually storing all duplicated information.

I do not know how to mark this, please help me.

+5
source share
1 answer

There are no built-in classes in the CLR that support different classes.

Related questions seem to have useful information ( i.e.Creating Delta Diff patches of large binary files in C # ). You can also search for a "Delta Encoding" search to get you started (i.e. http://en.wikipedia.org/wiki/Delta_encoding ).

+4

All Articles