public abstract class Diff extends Object
|Constructor and Description|
|Modifier and Type||Method and Description|
Creates single-window diff component that does not include any navigation controls and is controlled programatically via the returned DiffView interface.
Show the visual representation of the diff between two sources.
Get all visual diff presenters registered in the system.
Get the default visual diff presenter.
public static Diff getDefault()
public static Collection<? extends Diff> getAll()
public abstract Component createDiff(String name1, String title1, Reader r1, String name2, String title2, Reader r2, String MIMEType) throws IOException
name1- the name of the first source
title1- the title of the first source
r1- the first source
name2- the name of the second source
title2- the title of the second source
r2- the second resource compared with the first one.
MIMEType- the mime type of these sources
IOException- when the reading from input streams fails.
public DiffView createDiff(StreamSource s1, StreamSource s2) throws IOException
The StreamSource can be used to save the source content if it's modified
in the view. The view should not allow source modification if StreamSource.createWriter()
s1- the first source
s2- the second source
Built on October 25 2023. | Copyright © 2017-2023 Apache Software Foundation. All Rights Reserved.