Package org.eclipse.emf.compare.merge
Class IMerger.RegistryImpl
java.lang.Object
org.eclipse.emf.compare.merge.IMerger.RegistryImpl
- All Implemented Interfaces:
IMerger.Registry,IMerger.Registry2
- Enclosing interface:
- IMerger
A default implementation of an
IMerger.Registry. This is the implementation EMF Compare will
use through its GUI.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionAdds a merger to the registry.voidclear()Clear the registry.static IMerger.RegistryReturns a registry filled with the default mergers provided by EMF Compare; namelyAttributeChangeMerger,ReferenceChangeMerger,FeatureMapChangeMerger,ResourceAttachmentChangeMerger,PseudoConflictMergerandConflictMerger.getHighestRankingMerger(Diff target) Returns the merger, for the given target, owning the highest ranking.getMergers(Diff target) Returns the list of the candidate mergers for the given difference.getMergersByRankDescending(Diff diff, IMergeCriterion criterion) Provide the mergers sorted by rank descending.Removes a merger from the registry, from its class name.
-
Constructor Details
-
RegistryImpl
public RegistryImpl()Constructor.
-
-
Method Details
-
createStandaloneInstance
Returns a registry filled with the default mergers provided by EMF Compare; namelyAttributeChangeMerger,ReferenceChangeMerger,FeatureMapChangeMerger,ResourceAttachmentChangeMerger,PseudoConflictMergerandConflictMerger.- Returns:
- A registry filled with the default mergers provided by EMF Compare.
-
add
Adds a merger to the registry.- Specified by:
addin interfaceIMerger.Registry- Parameters:
merger- The merger.- Returns:
- The previously registered merger.
- See Also:
-
remove
Removes a merger from the registry, from its class name.- Specified by:
removein interfaceIMerger.Registry- Parameters:
className- The class name.- Returns:
- The previously registered merger.
- See Also:
-
clear
public void clear()Clear the registry.- Specified by:
clearin interfaceIMerger.Registry- See Also:
-
getHighestRankingMerger
Returns the merger, for the given target, owning the highest ranking.- Specified by:
getHighestRankingMergerin interfaceIMerger.Registry- Parameters:
target- The given target difference.- Returns:
- The found merger.
- See Also:
-
getMergersByRankDescending
Provide the mergers sorted by rank descending.- Specified by:
getMergersByRankDescendingin interfaceIMerger.Registry2- Parameters:
diff- The diffcriterion- The merge criterion, can benull- Returns:
- the registered mergers valid for the given diff and criterion, sorted by rank descending.
- Since:
- 3.3
-
getMergers
Returns the list of the candidate mergers for the given difference. If the given difference is null, return all known mergers.- Specified by:
getMergersin interfaceIMerger.Registry- Parameters:
target- The given difference.- Returns:
- The list of the found mergers.
- See Also:
-