Examples of PerformRefactoringOperation


Examples of org.eclipse.ltk.core.refactoring.PerformRefactoringOperation

          else {
            qualifiedName = newName;
          }
          p.setNewElementName(qualifiedName);
          Refactoring r = new RenameRefactoring(p);
          PerformRefactoringOperation op =
            new PerformRefactoringOperation(
                r,
                CheckConditionsOperation.FINAL_CONDITIONS
            );
          op.run(monitor);
          Object newElement = p.getNewElement();
          if(newElement instanceof IPackageFragment) {
            javaElement = (IPackageFragment)newElement;
          }
          /*
 
View Full Code Here

Examples of org.eclipse.ltk.core.refactoring.PerformRefactoringOperation

                      "constants.setterPrefix"
                  )
                  + field.getElementName()
              );
              r.setGenerateJavadoc(true);
              PerformRefactoringOperation op =
                new PerformRefactoringOperation(
                    r,
                    CheckConditionsOperation
                    .INITIAL_CONDITONS
                  );
              op.run(monitor);
              /*
               *   PerformRefactoringOperation op =
               *     new PerformRefactoringOperation(
               *       r,
               *       CheckConditionsOperation
 
View Full Code Here

Examples of org.eclipse.ltk.core.refactoring.PerformRefactoringOperation

        encapsulation.setGetterName("get" + field.getElementName());
        encapsulation.setSetterName("set" + field.getElementName());
        // encapsulation.setGenerateJavadoc(true);
        // encapsulation.setConsiderVisibility(true);
        Refactoring r = encapsulation;
        PerformRefactoringOperation op =
          new PerformRefactoringOperation(
              r,
              CheckConditionsOperation.INITIAL_CONDITONS
          );
        op.run(new NullProgressMonitor());
        /*
         *   PerformRefactoringOperation op =
         *     new PerformRefactoringOperation(
         *       r,
         *       CheckConditionsOperation
 
View Full Code Here

Examples of org.eclipse.ltk.core.refactoring.PerformRefactoringOperation

        RenameFieldProcessor p;
        try {
          p = new RenameFieldProcessor(javaElement);
          p.setNewElementName(newName);
          Refactoring r = new RenameRefactoring(p);
          PerformRefactoringOperation op =
            new PerformRefactoringOperation(
                r,
                CheckConditionsOperation.FINAL_CONDITIONS
            );
          op.run(monitor);
          // We get the parent java element
          IJavaElement parent = javaElement.getParent();
          if(parent instanceof IType) {
            IType t = (IType)parent;
            // From its children, we get the new property
View Full Code Here

Examples of org.eclipse.ltk.core.refactoring.PerformRefactoringOperation

                1,
                1,
                1
            )*/;
         
          PerformRefactoringOperation op =
            new PerformRefactoringOperation(
                r,
                CheckConditionsOperation.FINAL_CONDITIONS
            );
          op.run(monitor);
          // We get the parent java element
          IJavaElement parent = javaElement.getParent();
          if(parent instanceof IType) {
            IType t = (IType)parent;
            // From its children, we get the new property
View Full Code Here

Examples of org.eclipse.ltk.core.refactoring.PerformRefactoringOperation

            else {
              p = new RenameTypeProcessor(javaElement);
            }
            p.setNewElementName(newName);
            Refactoring r = new RenameRefactoring(p);
            PerformRefactoringOperation op =
              new PerformRefactoringOperation(
                  r,
                  CheckConditionsOperation.FINAL_CONDITIONS
              );
            op.run(monitor);
            ITypesContainerService contH = getContainerService();
            if(contH!=null) {
              String newFullName = contH.getFullName();
              newFullName += '.' + newName;
              IType tp = null;
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.