Class ResourceMappingMerger

    • Constructor Detail

      • ResourceMappingMerger

        public ResourceMappingMerger()
    • Method Detail

      • validateMerge

        public IStatus validateMerge​(IMergeContext mergeContext,
                                     IProgressMonitor monitor)
        Description copied from interface: IResourceMappingMerger
        Validate an auto-merge for the given context. This method must be invoked for all mergers involved in the merge before the auto-merge is attempted. The purpose of the validation is to indicate whether there are conditions in the merge context that make an auto-merge undesirable. The purpose is not to indicate that conflicts exist (this is done by the merge method) but instead to indicate that the nature of one of more incoming changes is such that performing an auto-merge may be undesirable.

        Clients should validate before performing the merge and, if any of the returned status are not OK, should prompt the user to make them aware of the potential side effects. The user may still decide to attempt an auto-merge, in which case the client may still invoke the merge method.

        Specified by:
        validateMerge in interface IResourceMappingMerger
        Parameters:
        mergeContext - a context that provides access to the resources involved in the merge. The context must not be null.
        monitor - a progress monitor
        Returns:
        a status indicating any potential side effects of performing an auto-merge.
      • getModelProvider

        protected abstract ModelProvider getModelProvider()
        Return the model provider associated with this merger.
        Returns:
        Return the model provider associated with this merger.