Class SimpleMergeResult
- java.lang.Object
-
- com.atlassian.confluence.util.diffs.SimpleMergeResult
-
- All Implemented Interfaces:
MergeResult
public class SimpleMergeResult extends Object implements MergeResult
-
-
Field Summary
Fields Modifier and Type Field Description static MergeResult
FAIL_MERGE_RESULT
-
Constructor Summary
Constructors Constructor Description SimpleMergeResult(boolean conflicts, String mergedContent)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getMergedContent()
Returns the result of the merge.boolean
hasConflicts()
True if the merge failed.
-
-
-
Field Detail
-
FAIL_MERGE_RESULT
public static final MergeResult FAIL_MERGE_RESULT
-
-
Constructor Detail
-
SimpleMergeResult
public SimpleMergeResult(boolean conflicts, String mergedContent)
-
-
Method Detail
-
getMergedContent
public String getMergedContent()
Description copied from interface:MergeResult
Returns the result of the merge. If the merge resulted in a conflict this method may return null, or a partially merged string. Implementers should return the data in the same format as the one that was passed in.- Specified by:
getMergedContent
in interfaceMergeResult
- Returns:
- result of merge if merge was successful, if the merge had conflicts the return value is undefined.
-
hasConflicts
public boolean hasConflicts()
Description copied from interface:MergeResult
True if the merge failed. If true is returned here the return value of getMergedContent() is undefined (likely null).- Specified by:
hasConflicts
in interfaceMergeResult
- Returns:
- true if the merge failed, otherwise false
-
-