org.electrocodeogram.cpc.core.api.provider.reconciler
Interface IDiffProvider

All Superinterfaces:
IProvider

public interface IDiffProvider
extends IProvider

A IDiffProvider provides character based diff services to other components.

A character based diff provides a hint at how the differences between two given text fragments may have occurred. There is no guarantee that the returned IDiffResults correspond to the real modifications made.

The actual diff algorithm used is not specified and it is up to the implementation how diffs are generated.

The most prominent user of this provider is the CPC Reconciler module.

Author:
vw
See Also:
IDiffResult

Method Summary
 java.util.List<IDiffResult> charDiff(java.lang.String oldText, java.lang.String newText)
          Computes a character based diff between the two given strings.
 
Methods inherited from interface org.electrocodeogram.cpc.core.api.provider.IProvider
getProviderName, toString
 

Method Detail

charDiff

java.util.List<IDiffResult> charDiff(java.lang.String oldText,
                                     java.lang.String newText)
Computes a character based diff between the two given strings.

Parameters:
oldText - the old text, never null.
newText - the new text, never null.
Returns:
a list of differences between the two strings, never null.