Class DelegatingMerger

java.lang.Object
org.eclipse.emf.compare.merge.DelegatingMerger

public class DelegatingMerger extends Object
Wrapper of mergers that makes sure that a given IMergeCriterion is passed to the wrapped merger before calling its merge method, and that the former value of criterion used by the wrapped merger is restored afterwards.
Since:
3.4
  • Constructor Details

    • DelegatingMerger

      public DelegatingMerger(IMerger merger, IMergeCriterion criterion)
      Constructor.
      Parameters:
      merger - The merger, cannot be null
      criterion - The criterion, can be null
  • Method Details

    • copyRightToLeft

      public void copyRightToLeft(Diff target, Monitor monitor)
      Call copyRightToLeft on the wrapped merger with the right criterion.
      Parameters:
      target - the diff
      monitor - the monitor
    • copyLeftToRight

      public void copyLeftToRight(Diff target, Monitor monitor)
      Call copyLeftToRight on the wrapped merger with the right criterion.
      Parameters:
      target - the diff
      monitor - the monitor
    • getMerger

      public IMerger getMerger()
    • getCriterion

      public IMergeCriterion getCriterion()