@Override public String toString() { return getSourceRange() + " in " + super.toString(); //$NON-NLS-1$ } }
@Override protected IFile[] getChangedFiles() throws CoreException { return ResourceUtil.getFiles(fChangeManager.getAllCompilationUnits()); }
public Change postCreateChange(Change[] participantChanges, IProgressMonitor pm) throws CoreException { if (fQualifiedNameSearchResult != null) { return fQualifiedNameSearchResult.getSingleChange(Changes.getModifiedFiles(participantChanges)); } else { return null; } }
@Override protected final void checkSelectedNodes() { super.checkSelectedNodes(); RefactoringStatus status= getStatus(); if (status.hasFatalError()) return; ASTNode node= getFirstSelectedNode(); if (node instanceof ArrayInitializer) { status.addFatalError(JavaManipulationMessages.CodeAnalyzer_array_initializer, JavaStatusContext.create(fCUnit, node)); } } }
@Override public void endVisit(ConstructorInvocation node) { if (getSelection().getEndVisitSelectionMode(node) == Selection.SELECTED) { invalidSelection(JavaManipulationMessages.SurroundWithTryCatchAnalyzer_cannotHandleThis, JavaStatusContext.create(fCUnit, node)); } super.endVisit(node); }
@Override public Object getCorrespondingElement() { if (isBinary()) return getClassFile(); else return getCompilationUnit(); } }
public static IResource getResource(Object o){ if (o instanceof IResource) return (IResource)o; if (o instanceof IJavaElement) return getResource((IJavaElement)o); return null; }
protected void addExceptions(ITypeBinding[] exceptions) { if(exceptions == null) return; for (int i= 0; i < exceptions.length;i++) { addException(exceptions[i]); } }
/** * Creates an status entry context for the given type root. * * @param typeRoot the type root containing the error * @return the status entry context or <code>Context.NULL_CONTEXT</code> if the * context cannot be created */ public static RefactoringStatusContext create(ITypeRoot typeRoot) { return create(typeRoot, (ISourceRange)null); }
@Override public String toString() { return getSourceRange() + " in " + super.toString(); //$NON-NLS-1$ } }
@Override protected IFile[] getChangedFiles() { return ResourceUtil.getFiles(fChangeManager.getAllCompilationUnits()); }
@Override public Change postCreateChange(Change[] participantChanges, IProgressMonitor pm) throws CoreException { if (fQualifiedNameSearchResult != null) { try { return fQualifiedNameSearchResult.getSingleChange(Changes.getModifiedFiles(participantChanges)); } finally { fQualifiedNameSearchResult= null; } } else { return null; } }
public static IResource getResource(Object o){ if (o instanceof IResource) return (IResource)o; if (o instanceof IJavaElement) return getResource((IJavaElement)o); return null; }
@Override protected IFile[] getChangedFiles() { return ResourceUtil.getFiles(fChangeManager.getAllCompilationUnits()); }
@Override public Change postCreateChange(Change[] participantChanges, IProgressMonitor pm) throws CoreException { if (fQualifiedNameSearchResult != null) { return fQualifiedNameSearchResult.getSingleChange(Changes.getModifiedFiles(participantChanges)); } else { return null; } }
protected IFile[] getChangedFiles() { return ResourceUtil.getFiles(fChangeManager.getAllCompilationUnits()); }
@Override public Change postCreateChange(Change[] participantChanges, IProgressMonitor pm) throws CoreException { if (fQualifiedNameSearchResult != null) { try { return fQualifiedNameSearchResult.getSingleChange(Changes.getModifiedFiles(participantChanges)); } finally { fQualifiedNameSearchResult= null; } } else { return null; } }
protected IFile[] getChangedFiles() throws CoreException { return ResourceUtil.getFiles(fChangeManager.getAllCompilationUnits()); }
public Change postCreateChange(Change[] participantChanges, IProgressMonitor pm) throws CoreException { if (fQualifiedNameSearchResult != null) { try { return fQualifiedNameSearchResult.getSingleChange(Changes.getModifiedFiles(participantChanges)); } finally { fQualifiedNameSearchResult= null; } } else { return null; } }
@Override public Change postCreateChange(Change[] participantChanges, IProgressMonitor pm) throws CoreException { if (fQualifiedNameSearchResult != null) { return fQualifiedNameSearchResult.getSingleChange(Changes.getModifiedFiles(participantChanges)); } else { return null; } }