Search
Simple declaration search will be available automatically, after
you specify sourceElementParser for your language and add search pages.
For search pages you need to extend
org.eclipse.search.searchPages extension point. There is
ScriptSearchPage class, you can use it like following:
public class RubySearchPage extends ScriptSearchPage {
protected IDLTKLanguageToolkit getLanguageToolkit() {
return RubyLanguageToolkit.getDefault();
}
}
For more advanced search you need to perform following tasks:
- Extend org.eclipse.dltk.core.search extension point. It will
provide ISearchFactory interface. With this interface you could specify
match parser, locator, and source indexer requester. For example you
could see RubySearchFactory or TclSearchFactory classes.
- MatchLocatorParser is used to parse selected module and report
all possible matches to pattern locator.
- SourceIndexerRequestor is used to report all needed things to
DLTK Index. Default implementation (SourceIndexerRequestor) report
model elements.