com.cloudbees.diff.provider
Class BuiltInDiffProvider

java.lang.Object
  extended by com.cloudbees.diff.provider.DiffProvider
      extended by com.cloudbees.diff.provider.BuiltInDiffProvider
All Implemented Interfaces:
Serializable

public class BuiltInDiffProvider
extends DiffProvider
implements Serializable

Author:
Martin Entlicher
See Also:
Serialized Form

Constructor Summary
BuiltInDiffProvider()
          Creates a new instance of BuiltInDiffProvider
 
Method Summary
 Diff computeDiff(Reader r1, Reader r2)
          Create the differences of the content two streams.
 boolean isTrimLines()
          On true all lines are trimmed before passing to diff engine.
 void setTrimLines(boolean trimLines)
          Setter for property trimLines.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BuiltInDiffProvider

public BuiltInDiffProvider()
Creates a new instance of BuiltInDiffProvider

Method Detail

computeDiff

public Diff computeDiff(Reader r1,
                        Reader r2)
                 throws IOException
Create the differences of the content two streams.

Specified by:
computeDiff in class DiffProvider
Parameters:
r1 - the first source
r2 - the second source to be compared with the first one.
Returns:
the list of differences found, instances of Difference; or null when some error occured.
Throws:
IOException - when the reading from input streams fails.

isTrimLines

public boolean isTrimLines()
On true all lines are trimmed before passing to diff engine.


setTrimLines

public void setTrimLines(boolean trimLines)
Setter for property trimLines.

Parameters:
trimLines - New value of property trimLines.


Copyright © 2011-2012. All Rights Reserved.