org.eclipse.xtext.ui.refactoring.impl
Class AbstractProcessorBasedRenameParticipant

java.lang.Object
  extended by org.eclipse.core.runtime.PlatformObject
      extended by org.eclipse.ltk.core.refactoring.participants.RefactoringParticipant
          extended by org.eclipse.ltk.core.refactoring.participants.RenameParticipant
              extended by org.eclipse.xtext.ui.refactoring.impl.AbstractProcessorBasedRenameParticipant
All Implemented Interfaces:
org.eclipse.core.runtime.IAdaptable
Direct Known Subclasses:
EcoreRefactoringParticipant, JdtRenameParticipant, OverridingRuleRefactoringParticipant

public abstract class AbstractProcessorBasedRenameParticipant
extends org.eclipse.ltk.core.refactoring.participants.RenameParticipant

A rename participant that triggers further rename refactorings based on RenameProcessors.

Author:
Jan Koehnlein - Initial contribution and API

Constructor Summary
AbstractProcessorBasedRenameParticipant()
           
 
Method Summary
 org.eclipse.ltk.core.refactoring.RefactoringStatus checkConditions(org.eclipse.core.runtime.IProgressMonitor pm, org.eclipse.ltk.core.refactoring.participants.CheckConditionsContext context)
           
 org.eclipse.ltk.core.refactoring.Change createChange(org.eclipse.core.runtime.IProgressMonitor pm)
           
protected  java.util.List<? extends IRenameElementContext> createRenameElementContexts(java.lang.Object element)
           
 void disableFor(java.lang.Object... elements)
           
 java.lang.Object[] getElements()
           
protected  IGlobalServiceProvider getGlobalServiceProvider()
           
 java.lang.String getName()
           
protected  java.lang.String getNewName()
           
protected abstract  java.util.List<org.eclipse.emf.ecore.EObject> getRenamedElementsOrProxies(org.eclipse.emf.ecore.EObject originalTarget)
           
protected  org.eclipse.ltk.core.refactoring.participants.RenameProcessor getRenameProcessor(IRenameElementContext participantContext)
           
protected  java.util.List<org.eclipse.ltk.core.refactoring.participants.RenameProcessor> getRenameProcessors(java.lang.Object originalTargetElement)
           
protected  IRenameRefactoringProvider getRenameRefactoringProvider(IRenameElementContext renameElementContext)
           
protected  StatusWrapper getStatus()
           
protected  boolean initialize(java.lang.Object originalTargetElement)
           
protected  void setNewName(org.eclipse.ltk.core.refactoring.participants.RenameProcessor processor, java.lang.String newName)
           
 
Methods inherited from class org.eclipse.ltk.core.refactoring.participants.RenameParticipant
getArguments, initialize
 
Methods inherited from class org.eclipse.ltk.core.refactoring.participants.RefactoringParticipant
createPreChange, getProcessor, getTextChange, initialize
 
Methods inherited from class org.eclipse.core.runtime.PlatformObject
getAdapter
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractProcessorBasedRenameParticipant

public AbstractProcessorBasedRenameParticipant()
Method Detail

initialize

protected boolean initialize(java.lang.Object originalTargetElement)
Specified by:
initialize in class org.eclipse.ltk.core.refactoring.participants.RefactoringParticipant

getRenameProcessors

protected java.util.List<org.eclipse.ltk.core.refactoring.participants.RenameProcessor> getRenameProcessors(java.lang.Object originalTargetElement)

getRenameProcessor

protected org.eclipse.ltk.core.refactoring.participants.RenameProcessor getRenameProcessor(IRenameElementContext participantContext)

getRenameRefactoringProvider

protected IRenameRefactoringProvider getRenameRefactoringProvider(IRenameElementContext renameElementContext)

getName

public java.lang.String getName()
Specified by:
getName in class org.eclipse.ltk.core.refactoring.participants.RefactoringParticipant

getElements

public java.lang.Object[] getElements()

disableFor

public void disableFor(java.lang.Object... elements)

checkConditions

public org.eclipse.ltk.core.refactoring.RefactoringStatus checkConditions(org.eclipse.core.runtime.IProgressMonitor pm,
                                                                          org.eclipse.ltk.core.refactoring.participants.CheckConditionsContext context)
                                                                   throws org.eclipse.core.runtime.OperationCanceledException
Specified by:
checkConditions in class org.eclipse.ltk.core.refactoring.participants.RefactoringParticipant
Throws:
org.eclipse.core.runtime.OperationCanceledException

setNewName

protected void setNewName(org.eclipse.ltk.core.refactoring.participants.RenameProcessor processor,
                          java.lang.String newName)

createChange

public org.eclipse.ltk.core.refactoring.Change createChange(org.eclipse.core.runtime.IProgressMonitor pm)
                                                     throws org.eclipse.core.runtime.CoreException,
                                                            org.eclipse.core.runtime.OperationCanceledException
Specified by:
createChange in class org.eclipse.ltk.core.refactoring.participants.RefactoringParticipant
Throws:
org.eclipse.core.runtime.CoreException
org.eclipse.core.runtime.OperationCanceledException

createRenameElementContexts

protected java.util.List<? extends IRenameElementContext> createRenameElementContexts(java.lang.Object element)

getRenamedElementsOrProxies

protected abstract java.util.List<org.eclipse.emf.ecore.EObject> getRenamedElementsOrProxies(org.eclipse.emf.ecore.EObject originalTarget)

getNewName

protected java.lang.String getNewName()

getStatus

protected StatusWrapper getStatus()

getGlobalServiceProvider

protected IGlobalServiceProvider getGlobalServiceProvider()