pub struct UnifiedDiffBuilder<'a, W, T>where
    W: Write,
    T: Hash + Eq + Display,
{ /* private fields */ }
Expand description

A Sink that creates a textual diff in the format typically output by git or gnu-diff if the -u option is used

Implementations

Create a new UnifiedDiffBuilder for the given input, that will return a String.

Create a new UnifiedDiffBuilder for the given input, that will writes it output to the provided implementation of Write.

Trait Implementations

This method is called whenever a diff algorithm finds a change between the two processed input file. A change is a continous subsequence of tokens before that needs to be replaced by a different contious subsequence of tokens after to construct the seconds file from the first. Read more
This function is called after all calls to process_change are complete to obtain the final diff result Read more
Utility method that constructs a Counter that tracks the total number of inserted and removed tokens in the changes passed to process_change. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.