Performance with SearchEngine [message #990603] |
Thu, 13 December 2012 11:55 |
|
Hi,
I'm developing a plugin to create methods in my project.
I need provide all classes that can be accessible by a class that I'm editing.
I use the SearchEngine to find Classes to provide proposals, but if I define my research (scope) for "SOURCES | APPLICATION_LIBRARIES | REFERENCED_PROJECTS | SYSTEM_LIBRARIES" sometimes it's slowly or I get one "OutOfMemory". (Searching for CLASS_AND_INTERFACE | DECLARATIONS).
Researching how the eclipse is so fast in your researches I find that uses an "Index" (stored in '.metadata' of the 'workspace') and keep the results in memory.
I'm thinkin to keep the result of search "SYSTEM_LIBRARIES" (in the first request and exclude from the scope of research) in memory (static var in my plugin) and after that, filter this static list by the text typed, I'll do this in one class that extends TypeNameMatchRequestor. Any way, if my project has a lot of libraries my research still slow.
Is there a way to use "indexes" of the eclipse?
You know another solution for this case? (Provide any accessible classes, filtered by text typed, quickly and safely).
Sometime I saw that is not recommended to use static variables in the plugin, I'll take issue with this "solution"?
Thanks.
|
|
|
|
Powered by
FUDForum. Page generated in 0.03040 seconds