return new JavaRefactoringDescriptor(ID_RENAME_TYPE, project, Messages.format(RefactoringCoreMessages.RenameTypeProcessor_descriptor_description, new String[] { JavaElementLabels.getElementLabel(fType, JavaElementLabels.ALL_FULLY_QUALIFIED), getNewElementName()}), getComment(), arguments, flags);
JavaRefactoringDescriptor descriptor= new JavaRefactoringDescriptor(ID_RENAME_TYPE, project, Messages.format(RefactoringCoreMessages.RenameTypeProcessor_descriptor_description, new String[] { JavaElementLabels.getElementLabel(fType, JavaElementLabels.ALL_FULLY_QUALIFIED), getNewElementName()}), getComment(), arguments, flags); return new RefactoringChangeDescriptor(descriptor);
	public Change createChange(IProgressMonitor monitor) throws CoreException {		try {			monitor.beginTask(RefactoringCoreMessages.RenameTypeRefactoring_creating_change, 4);			final DynamicValidationStateChange result= new DynamicValidationStateChange(RefactoringCoreMessages.Change_javaChanges) {				public final ChangeDescriptor getDescriptor() {					final Map arguments= new HashMap();					arguments.put(JavaRefactoringDescriptor.INPUT, fType.getHandleIdentifier());					arguments.put(JavaRefactoringDescriptor.NAME, getNewElementName());					if (fFilePatterns != null && !"".equals(fFilePatterns)) //$NON-NLS-1$						arguments.put(ATTRIBUTE_PATTERNS, fFilePatterns);					arguments.put(ATTRIBUTE_REFERENCES, Boolean.valueOf(fUpdateReferences).toString());					arguments.put(ATTRIBUTE_QUALIFIED, Boolean.valueOf(fUpdateQualifiedNames).toString());					arguments.put(ATTRIBUTE_TEXTUAL_MATCHES, Boolean.valueOf(fUpdateTextualMatches).toString());					arguments.put(ATTRIBUTE_SIMILAR_DECLARATIONS, Boolean.valueOf(fUpdateSimilarElements).toString());					arguments.put(ATTRIBUTE_SIMILAR_DECLARATIONS_MATCHING_STRATEGY, Integer.toString(fRenamingStrategy));					String project= null;					IJavaProject javaProject= fType.getJavaProject();					if (javaProject != null)						project= javaProject.getElementName();					int flags= JavaRefactorings.JAR_IMPORTABLE | RefactoringDescriptor.STRUCTURAL_CHANGE;					try {						if (!Flags.isPrivate(fType.getFlags()))							flags|= RefactoringDescriptor.MULTI_CHANGE;					} catch (JavaModelException exception) {						JavaPlugin.log(exception);					}					return new JavaRefactoringDescriptor(ID_RENAME_TYPE, project, Messages.format(RefactoringCoreMessages.RenameTypeProcessor_descriptor_description, new String[] { JavaElementLabels.getElementLabel(fType, JavaElementLabels.ALL_FULLY_QUALIFIED), getNewElementName()}), getComment(), arguments, flags);				}			};			result.addAll(fChangeManager.getAllChanges());			if (willRenameCU()) {				IResource resource= ResourceUtil.getResource(fType);				if (resource != null && resource.isLinked()) {					String ext= resource.getFileExtension();					String renamedResourceName;					if (ext == null)						renamedResourceName= getNewElementName();					else						renamedResourceName= getNewElementName() + '.' + ext;					result.add(new RenameResourceChange(ResourceUtil.getResource(fType), renamedResourceName, getComment()));				} else {					String renamedCUName= JavaModelUtil.getRenamedCUName(fType.getCompilationUnit(), getNewElementName());					result.add(new RenameCompilationUnitChange(fType.getCompilationUnit(), renamedCUName, getComment()));				}			}			monitor.worked(1);			return result;		} finally {			fChangeManager= null;		}	}