Java Code Examples for org.eclipse.ltk.core.refactoring.participants.ValidateEditChecker#addFile()

The following examples show how to use org.eclipse.ltk.core.refactoring.participants.ValidateEditChecker#addFile() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: RenameModifications.java    From eclipse.jdt.ls with Eclipse Public License 2.0 5 votes vote down vote up
@Override
public void buildValidateEdits(ValidateEditChecker checker) {
	for (Iterator<Object> iter= fRename.iterator(); iter.hasNext();) {
		Object element= iter.next();
		if (element instanceof ICompilationUnit) {
			ICompilationUnit unit= (ICompilationUnit)element;
			IResource resource= unit.getResource();
			if (resource != null && resource.getType() == IResource.FILE) {
				checker.addFile((IFile)resource);
			}
		}
	}
}
 
Example 2
Source File: MoveModifications.java    From eclipse.jdt.ls with Eclipse Public License 2.0 5 votes vote down vote up
@Override
public void buildValidateEdits(ValidateEditChecker checker) {
	for (Iterator<Object> iter= fMoves.iterator(); iter.hasNext();) {
		Object element= iter.next();
		if (element instanceof ICompilationUnit) {
			ICompilationUnit unit= (ICompilationUnit)element;
			IResource resource= unit.getResource();
			if (resource != null && resource.getType() == IResource.FILE) {
				checker.addFile((IFile)resource);
			}
		}
	}
}
 
Example 3
Source File: RenameModifications.java    From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 5 votes vote down vote up
@Override
public void buildValidateEdits(ValidateEditChecker checker) {
	for (Iterator<Object> iter= fRename.iterator(); iter.hasNext();) {
		Object element= iter.next();
		if (element instanceof ICompilationUnit) {
			ICompilationUnit unit= (ICompilationUnit)element;
			IResource resource= unit.getResource();
			if (resource != null && resource.getType() == IResource.FILE) {
				checker.addFile((IFile)resource);
			}
		}
	}
}
 
Example 4
Source File: MoveModifications.java    From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 5 votes vote down vote up
@Override
public void buildValidateEdits(ValidateEditChecker checker) {
	for (Iterator<Object> iter= fMoves.iterator(); iter.hasNext();) {
		Object element= iter.next();
		if (element instanceof ICompilationUnit) {
			ICompilationUnit unit= (ICompilationUnit)element;
			IResource resource= unit.getResource();
			if (resource != null && resource.getType() == IResource.FILE) {
				checker.addFile((IFile)resource);
			}
		}
	}
}