1 11 package org.eclipse.jdt.internal.ui.fix; 12 13 import java.util.Map ; 14 15 import org.eclipse.core.runtime.CoreException; 16 import org.eclipse.core.runtime.IProgressMonitor; 17 18 import org.eclipse.ltk.core.refactoring.RefactoringStatus; 19 20 import org.eclipse.jdt.core.ICompilationUnit; 21 import org.eclipse.jdt.core.IJavaProject; 22 import org.eclipse.jdt.core.dom.CompilationUnit; 23 24 import org.eclipse.jdt.internal.corext.fix.IFix; 25 26 import org.eclipse.jdt.ui.text.java.IProblemLocation; 27 28 36 public interface ICleanUp { 37 38 54 public abstract boolean requireAST(ICompilationUnit unit) throws CoreException; 55 56 67 public abstract IFix createFix(ICompilationUnit unit) throws CoreException; 68 69 81 public abstract IFix createFix(CompilationUnit compilationUnit) throws CoreException; 82 83 94 public abstract IFix createFix(CompilationUnit compilationUnit, IProblemLocation[] problems) throws CoreException; 95 96 102 public abstract Map getRequiredOptions(); 103 104 112 public abstract boolean needsFreshAST(CompilationUnit compilationUnit); 113 114 119 public String [] getDescriptions(); 120 121 public void initialize(Map settings) throws CoreException; 122 123 136 public abstract RefactoringStatus checkPreConditions(IJavaProject project, ICompilationUnit[] compilationUnits, IProgressMonitor monitor) throws CoreException; 137 138 145 public abstract RefactoringStatus checkPostConditions(IProgressMonitor monitor) throws CoreException; 146 147 160 public boolean canFix(CompilationUnit compilationUnit, IProblemLocation problem) throws CoreException; 161 162 170 public abstract int maximalNumberOfFixes(CompilationUnit compilationUnit); 171 172 177 public abstract String getPreview(); 178 179 } 180 | Popular Tags |