|
Eclipse Platform Release 3.3 |
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.ltk.core.refactoring.PerformRefactoringHistoryOperation
Operation that, when run, executes a series of refactoring sequentially.
Refactorings are executed using PerformRefactoringOperation
.
The operation should be executed via the run method offered by
IWorkspace
to achieve proper delta batching.
Note: this class is not intended to be instantiated or extended outside of the refactoring framework.
IWorkspace
,
PerformRefactoringOperation
,
RefactoringHistory
,
RefactoringHistoryService
Constructor Summary | |
---|---|
PerformRefactoringHistoryOperation(RefactoringHistory history)
Creates a new perform refactoring history operation. |
Method Summary | |
---|---|
protected RefactoringStatus |
aboutToPerformRefactoring(Refactoring refactoring,
RefactoringDescriptor descriptor,
IProgressMonitor monitor)
Hook method which is called when the specified refactoring is going to be executed. |
protected Refactoring |
createRefactoring(RefactoringDescriptor descriptor,
RefactoringStatus status)
Method which is called to create a refactoring instance from a refactoring descriptor. |
RefactoringStatus |
getExecutionStatus()
Returns the execution status. |
protected void |
refactoringPerformed(Refactoring refactoring,
IProgressMonitor monitor)
Hook method which is called when the specified refactoring has been performed. |
void |
run(IProgressMonitor monitor)
Runs the operation reporting progress to and accepting cancellation requests from the given progress monitor.
Implementors of this method should check the progress monitor
for cancellation when it is safe and appropriate to do so. The cancellation
request should be propagated to the caller by throwing
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public PerformRefactoringHistoryOperation(RefactoringHistory history)
history
- the refactoring historyMethod Detail |
protected RefactoringStatus aboutToPerformRefactoring(Refactoring refactoring, RefactoringDescriptor descriptor, IProgressMonitor monitor)
refactoring
- the refactoring about to be executeddescriptor
- the refactoring descriptormonitor
- the progress monitor to use
protected Refactoring createRefactoring(RefactoringDescriptor descriptor, RefactoringStatus status) throws CoreException
descriptor
- the refactoring descriptorstatus
- a refactoring status to describe the outcome of the
initialization
null
if this refactoring
descriptor represents the unknown refactoring, or if no
refactoring contribution is available for this refactoring
descriptor
CoreException
- if an error occurs while creating the refactoring instancepublic final RefactoringStatus getExecutionStatus()
null
.
protected void refactoringPerformed(Refactoring refactoring, IProgressMonitor monitor)
refactoring
- the refactoring which has been performedmonitor
- the progress monitor to usepublic void run(IProgressMonitor monitor) throws CoreException
Implementors of this method should check the progress monitor
for cancellation when it is safe and appropriate to do so. The cancellation
request should be propagated to the caller by throwing
OperationCanceledException
.
run
in interface IWorkspaceRunnable
monitor
- a progress monitor, or null
if progress
reporting and cancellation are not desired
CoreException
- if this operation fails.
|
Eclipse Platform Release 3.3 |
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Guidelines for using Eclipse APIs.
Copyright (c) IBM Corp. and others 2000, 2007. All rights reserved.