*/
private Change createChange(JavaSearchDocumentDelegate searchDoc, TextEdit edit, RefactoringParticipant participant) {
IDocument doc = searchDoc.getJspTranslation().getJspDocument();
String description = getDescription();
TextChange existingChange = participant.getTextChange(searchDoc.getFile());
TextChange change = null;
if(existingChange != null) {
try {
existingChange.addEdit(edit);
}catch (MalformedTreeException e) {
Logger.logException("MalformedTreeException while adding edit " + //$NON-NLS-1$
edit + " to existing change " + change, e); //$NON-NLS-1$
}
TextEditGroup group = new TextEditGroup(description, edit);
existingChange.addTextEditGroup(group);
} else {
change = new JSPRenameChange(searchDoc.getFile(), doc, edit, searchDoc.getFile().getName());
TextEditGroup group = new TextEditGroup(description, edit);
change.addTextEditGroup(group);
}
return change;
}