]> git.uio.no Git - ifi-stolz-refaktor.git/commitdiff
Some simple renamings.
authorErlend Kristiansen <erlenkr@ifi.uio.no>
Tue, 10 Dec 2013 12:09:12 +0000 (13:09 +0100)
committerErlend Kristiansen <erlenkr@ifi.uio.no>
Tue, 10 Dec 2013 12:12:15 +0000 (13:12 +0100)
software/no.uio.ifi.refaktor/src/no/uio/ifi/refaktor/changers/ExtractAndMoveMethodExecutor.java

index eddf876015ab30402e16971c3c77263597a9c4fe..a0374c48da163df6195bd5cec9e1f7df30906a40 100644 (file)
@@ -43,7 +43,7 @@ public class ExtractAndMoveMethodExecutor implements Executor {
        private String newMethodName;
        private String newMethodSignature;
        private MoveMethodRefactoringTargetFinder targetFinder;
-       private RefactoringPerformer refactoringExecutor;
+       private RefactoringPerformer refactoringPerformer;
 
        public ExtractAndMoveMethodExecutor(CompilationUnitTextSelection compilationUnitTextSelection, String newMethodName) {
                this.compilationUnitTextSelection = compilationUnitTextSelection;
@@ -62,22 +62,22 @@ public class ExtractAndMoveMethodExecutor implements Executor {
 
        @Override
        public void executeChange(IProgressMonitor monitor, UndoResources undoResources) throws CoreException {
-               createRefactoringExecutor(monitor, undoResources);
-               checkConditionsAndPerformExtractMethodRefactoring();
-               checkConditionsAndPerformMoveMethodRefactoring();
+               createRefactoringPerformer(monitor, undoResources);
+               performExtractMethodRefactoring();
+               performMoveMethodRefactoring();
        }
 
-       private void checkConditionsAndPerformExtractMethodRefactoring() throws CoreException {
+       private void performExtractMethodRefactoring() throws CoreException {
                ExtractMethodRefactoring extractMethodRefactoring = createExtractMethodRefactoring();
-               refactoringExecutor.performRefactoring(extractMethodRefactoring);
+               refactoringPerformer.performRefactoring(extractMethodRefactoring);
                assertThatNewMethodNameWasUsedWhenPerformingRefactoring(extractMethodRefactoring);
                setNewMethodSignature(extractMethodRefactoring);
                createMoveMethodRefactoringTargetFinder(extractMethodRefactoring);
        }
 
-       private void checkConditionsAndPerformMoveMethodRefactoring() throws JavaModelException, CoreException {
+       private void performMoveMethodRefactoring() throws JavaModelException, CoreException {
                // Here, the method we'd like to move must already exist since we need to look up an IMethod handle:
-               refactoringExecutor.performRefactoring(createMoveRefactoring());
+               refactoringPerformer.performRefactoring(createMoveRefactoring());
        }
 
        private ExtractMethodRefactoring createExtractMethodRefactoring() throws CoreException {
@@ -148,8 +148,8 @@ public class ExtractAndMoveMethodExecutor implements Executor {
                return method;
        }
 
-       private void createRefactoringExecutor(IProgressMonitor monitor, UndoResources undoResources) {
-               refactoringExecutor = new SimpleRefactoringPerformer(monitor, undoResources);
+       private void createRefactoringPerformer(IProgressMonitor monitor, UndoResources undoResources) {
+               refactoringPerformer = new SimpleRefactoringPerformer(monitor, undoResources);
        }
 
 }
\ No newline at end of file