Class BslReferenceUpdater

  • All Implemented Interfaces:
    org.eclipse.xtext.ui.refactoring.IReferenceUpdater
    Direct Known Subclasses:
    BslBmReferenceUpdater

    public class BslReferenceUpdater
    extends org.eclipse.xtext.ui.refactoring.impl.DefaultReferenceUpdater
    Reference updater for Bsl. Handles references from FeatureEntrys as a special case.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected org.eclipse.xtext.ui.refactoring.impl.RefactoringResourceSetProvider resourceSetProvider
      Provides special ResourceSet for refactoring operations
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected void createBslReferenceUpdate​(org.eclipse.emf.ecore.EObject referringElement, org.eclipse.emf.common.util.URI referringResourceURI, org.eclipse.emf.ecore.EReference reference, int indexInList, org.eclipse.emf.ecore.EObject newTargetElement, String newReferenceText, int originalOffset, org.eclipse.xtext.ui.refactoring.IRefactoringUpdateAcceptor updateAcceptor)
      Creates references update for Bsl model
      protected void createReferenceUpdate​(org.eclipse.xtext.resource.IReferenceDescription referenceDescription, org.eclipse.emf.common.util.URI referringResourceURI, org.eclipse.xtext.ui.refactoring.ElementRenameArguments elementRenameArguments, org.eclipse.emf.ecore.resource.ResourceSet resourceSet, org.eclipse.xtext.ui.refactoring.IRefactoringUpdateAcceptor updateAcceptor)  
      void createReferenceUpdates​(org.eclipse.xtext.ui.refactoring.ElementRenameArguments elementRenameArguments, Iterable<org.eclipse.xtext.resource.IReferenceDescription> referenceDescriptions, org.eclipse.xtext.ui.refactoring.IRefactoringUpdateAcceptor updateAcceptor, org.eclipse.core.runtime.IProgressMonitor monitor)  
      protected boolean loadTargetResources​(org.eclipse.emf.ecore.resource.ResourceSet resourceSet, org.eclipse.xtext.ui.refactoring.ElementRenameArguments elementRenameArguments, org.eclipse.xtext.ui.refactoring.impl.StatusWrapper status, org.eclipse.core.runtime.IProgressMonitor monitor)  
      protected org.eclipse.emf.ecore.EObject resolveReference​(org.eclipse.emf.ecore.EObject referringElement, org.eclipse.xtext.resource.IReferenceDescription referenceDescription)  
      protected List<org.eclipse.xtext.resource.IReferenceDescription> resolveReferenceProxies​(org.eclipse.emf.ecore.resource.ResourceSet resourceSet, Collection<org.eclipse.xtext.resource.IReferenceDescription> values, org.eclipse.xtext.ui.refactoring.impl.StatusWrapper status, org.eclipse.core.runtime.IProgressMonitor monitor)  
      • Methods inherited from class org.eclipse.xtext.ui.refactoring.impl.DefaultReferenceUpdater

        createReferenceUpdate, createReferenceUpdates, createTextChange, getCrossReference, getLocationInFileProvider, getRefTextEvaluator, getTransientValueService, processReferringResource, resolveNameConflict
      • Methods inherited from class org.eclipse.xtext.ui.refactoring.impl.AbstractReferenceUpdater

        createClusteredReferenceUpdates, createReferenceUpdates, createReferenceUpdatesForCluster, getClusterSize, handleCannotLoadReferringElement, handleCannotResolveExistingReference, loadReferringResources, unloadNonTargetResources
    • Field Detail

      • resourceSetProvider

        @Inject
        protected org.eclipse.xtext.ui.refactoring.impl.RefactoringResourceSetProvider resourceSetProvider
        Provides special ResourceSet for refactoring operations
    • Constructor Detail

      • BslReferenceUpdater

        public BslReferenceUpdater()
    • Method Detail

      • createReferenceUpdates

        public void createReferenceUpdates​(org.eclipse.xtext.ui.refactoring.ElementRenameArguments elementRenameArguments,
                                           Iterable<org.eclipse.xtext.resource.IReferenceDescription> referenceDescriptions,
                                           org.eclipse.xtext.ui.refactoring.IRefactoringUpdateAcceptor updateAcceptor,
                                           org.eclipse.core.runtime.IProgressMonitor monitor)
        Specified by:
        createReferenceUpdates in interface org.eclipse.xtext.ui.refactoring.IReferenceUpdater
        Overrides:
        createReferenceUpdates in class org.eclipse.xtext.ui.refactoring.impl.AbstractReferenceUpdater
      • createBslReferenceUpdate

        protected void createBslReferenceUpdate​(org.eclipse.emf.ecore.EObject referringElement,
                                                org.eclipse.emf.common.util.URI referringResourceURI,
                                                org.eclipse.emf.ecore.EReference reference,
                                                int indexInList,
                                                org.eclipse.emf.ecore.EObject newTargetElement,
                                                String newReferenceText,
                                                int originalOffset,
                                                org.eclipse.xtext.ui.refactoring.IRefactoringUpdateAcceptor updateAcceptor)
        Creates references update for Bsl model
        Parameters:
        referringElement - updated element, can't be null
        referringResourceURI - uri of updated element resource, can't be null
        reference - actual references which will be updated in updated element, can't be null
        indexInList - position in list of reference features
        newTargetElement - renaming element, can't be null
        newReferenceText - new text of updated element reference, can't be null
        originalOffset - offset of renaming element or -1 if there is no offset
        updateAcceptor - acceptor for text updates, can't be null
      • createReferenceUpdate

        protected void createReferenceUpdate​(org.eclipse.xtext.resource.IReferenceDescription referenceDescription,
                                             org.eclipse.emf.common.util.URI referringResourceURI,
                                             org.eclipse.xtext.ui.refactoring.ElementRenameArguments elementRenameArguments,
                                             org.eclipse.emf.ecore.resource.ResourceSet resourceSet,
                                             org.eclipse.xtext.ui.refactoring.IRefactoringUpdateAcceptor updateAcceptor)
        Overrides:
        createReferenceUpdate in class org.eclipse.xtext.ui.refactoring.impl.DefaultReferenceUpdater
      • resolveReference

        protected org.eclipse.emf.ecore.EObject resolveReference​(org.eclipse.emf.ecore.EObject referringElement,
                                                                 org.eclipse.xtext.resource.IReferenceDescription referenceDescription)
        Overrides:
        resolveReference in class org.eclipse.xtext.ui.refactoring.impl.AbstractReferenceUpdater
      • resolveReferenceProxies

        protected List<org.eclipse.xtext.resource.IReferenceDescription> resolveReferenceProxies​(org.eclipse.emf.ecore.resource.ResourceSet resourceSet,
                                                                                                 Collection<org.eclipse.xtext.resource.IReferenceDescription> values,
                                                                                                 org.eclipse.xtext.ui.refactoring.impl.StatusWrapper status,
                                                                                                 org.eclipse.core.runtime.IProgressMonitor monitor)
        Overrides:
        resolveReferenceProxies in class org.eclipse.xtext.ui.refactoring.impl.AbstractReferenceUpdater
      • loadTargetResources

        protected boolean loadTargetResources​(org.eclipse.emf.ecore.resource.ResourceSet resourceSet,
                                              org.eclipse.xtext.ui.refactoring.ElementRenameArguments elementRenameArguments,
                                              org.eclipse.xtext.ui.refactoring.impl.StatusWrapper status,
                                              org.eclipse.core.runtime.IProgressMonitor monitor)
        Overrides:
        loadTargetResources in class org.eclipse.xtext.ui.refactoring.impl.AbstractReferenceUpdater