Class DocumentDiff3
- java.lang.Object
-
- org.apache.jackrabbit.vault.util.diff.DocumentDiff3
-
-
Constructor Summary
Constructors Constructor Description DocumentDiff3(Document base, Document left, Document right)
Creates a new document diff 3 object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Hunk3
getHunks()
Returns a chain ofHunk3
s that contain the modifications.boolean
hasConflicts()
Indicates if any of the hunks has a conflict.void
write(StringBuffer buf, String lineSeparator, boolean showBase)
Writes the resulting document to the given string buffer. this may include conflicting regions.void
write(DiffWriter w, boolean showBase)
Writes the resulting document to the given write. this may include conflicting regions.
-
-
-
Method Detail
-
getHunks
public Hunk3 getHunks()
Returns a chain ofHunk3
s that contain the modifications.- Returns:
- a chain of
Hunk3
s.
-
hasConflicts
public boolean hasConflicts()
Indicates if any of the hunks has a conflict.- Returns:
true
if any of the hunks has a conflict.
-
write
public void write(StringBuffer buf, String lineSeparator, boolean showBase)
Writes the resulting document to the given string buffer. this may include conflicting regions.- Parameters:
buf
- the string buffer to write tolineSeparator
- the line separator to useshowBase
- if set totrue
the base section of a conflict is also included in the output.
-
write
public void write(DiffWriter w, boolean showBase) throws IOException
Writes the resulting document to the given write. this may include conflicting regions.- Parameters:
w
- the writer to write toshowBase
- if set totrue
the base section of a conflict is also included in the output.- Throws:
IOException
- if an I/O error occurs
-
-