Package ghidra.app.merge.tree
Class ProgramTreeMergeManager
java.lang.Object
ghidra.app.merge.tree.ProgramTreeMergeManager
- All Implemented Interfaces:
MergeResolver
Manages changes and conflicts between the latest versioned Program and the
Program that is being checked into version control.
-
Constructor Summary
ConstructorsConstructorDescriptionProgramTreeMergeManager(ProgramMultiUserMergeManager mergeManager, Program resultProgram, Program myProgram, Program originalProgram, Program latestProgram, ProgramChangeSet latestChangeSet, ProgramChangeSet myChangeSet) Construct a new manager for merging trees -
Method Summary
Modifier and TypeMethodDescriptionvoidapply()Notification that the apply button was hit.voidcancel()Notification that the merge process was canceled.Get the description of what this MergeResolver does.getName()Get the name of this MergeResolver.String[][]Gets identifiers for the merge phases handled by this MergeResolver.voidmerge(TaskMonitor monitor) Perform the merge process.
-
Constructor Details
-
ProgramTreeMergeManager
public ProgramTreeMergeManager(ProgramMultiUserMergeManager mergeManager, Program resultProgram, Program myProgram, Program originalProgram, Program latestProgram, ProgramChangeSet latestChangeSet, ProgramChangeSet myChangeSet) Construct a new manager for merging trees- Parameters:
mergeManager- the program merge managerresultProgram- latest version of the Program that is the destination for changes applied from the source programmyProgram- source of changes to apply to the destination programoriginalProgram- program that was originally checked outlatestProgram- program that is the latest version; the resultProgram and latestProgram start out as being identicallatestChangeSet- change set of the destination programmyChangeSet- change set for the source program
-
-
Method Details
-
apply
public void apply()Description copied from interface:MergeResolverNotification that the apply button was hit.- Specified by:
applyin interfaceMergeResolver
-
cancel
public void cancel()Description copied from interface:MergeResolverNotification that the merge process was canceled.- Specified by:
cancelin interfaceMergeResolver
-
getDescription
Description copied from interface:MergeResolverGet the description of what this MergeResolver does.- Specified by:
getDescriptionin interfaceMergeResolver
-
getName
Description copied from interface:MergeResolverGet the name of this MergeResolver.- Specified by:
getNamein interfaceMergeResolver
-
merge
Description copied from interface:MergeResolverPerform the merge process.- Specified by:
mergein interfaceMergeResolver- Parameters:
monitor- monitor that allows the user to cancel the merge operation
-
getPhases
Description copied from interface:MergeResolverGets identifiers for the merge phases handled by this MergeResolver. If the merge has no sub-phases then return an array with a single string array. Each inner String array indicates a path for a single merge phase. Each outer array element represents a phase whose progress we wish to indicate.
Examples:
So for a simple phase which has no sub-phases returnnew String[][] {new String[] {"Phase A"}}
So for a phase with 2 sub-phases returnnew String[][] { new String[] {"Phase A"}, new String[] {"Phase A", "Sub-Phase 1}, new String[] {"Phase A", "Sub-Phase 2} }.- Specified by:
getPhasesin interfaceMergeResolver- Returns:
- an array of phases.
-