use of org.eclipse.wst.jsdt.core.search.SearchDocument in project webtools.sourceediting by eclipse.
the class BasicRefactorSearchRequestor method getChanges.
/**
* @return all JSP changes for the search matches for the given Type
*/
public Change[] getChanges() {
JsSearchSupport support = JsSearchSupport.getInstance();
List changes = new ArrayList();
Iterator keys = fSearchDocPath2JavaEditMap.keySet().iterator();
String searchDocPath = null;
SearchDocument delegate = null;
while (keys.hasNext()) {
// create on the fly
searchDocPath = (String) keys.next();
MultiTextEdit javaEdit = (MultiTextEdit) fSearchDocPath2JavaEditMap.get(searchDocPath);
delegate = support.getSearchDocument(searchDocPath);
if (delegate != null && delegate instanceof JSDTSearchDocumentDelegate) {
JSDTSearchDocumentDelegate javaDelegate = (JSDTSearchDocumentDelegate) delegate;
changes.add(createChange(javaDelegate, javaEdit));
}
}
return (Change[]) changes.toArray(new Change[changes.size()]);
}
Aggregations