use of org.eclipse.che.plugin.java.server.refactoring.session.ReorgRefactoringSession in project che by eclipse.
the class RefactoringManager method setRefactoringDestination.
public RefactoringStatus setRefactoringDestination(ReorgDestination destination) throws RefactoringException, JavaModelException {
RefactoringSession session = getRefactoringSession(destination.getSessionId());
if (!(session instanceof ReorgRefactoringSession)) {
throw new RefactoringException("Can't set destination on none reorg refactoring session.");
}
ReorgRefactoringSession rs = ((ReorgRefactoringSession) session);
Object dest = getDestination(destination.getProjectPath(), destination.getType(), destination.getDestination());
org.eclipse.ltk.core.refactoring.RefactoringStatus refactoringStatus = rs.verifyDestination(dest);
return DtoConverter.toRefactoringStatusDto(refactoringStatus);
}
Aggregations