Eclipse Plugin - Get External Method?

I am developing a plugin for Eclipse. The plugin has a couple of views that need to be updated when the caret is moved in the active editor to reflect the external method.

I am currently getting an ASTNode that represents an external method using the ASTParser class for the entire source for a file and then traversing its hierarchy until I find the external method. This works fine for moderate code size files, but appears to be slower for very large code files.

I was wondering if there is a built-in function that can give me a view of an external method that might be more efficient than my current approach? I looked high and low, but maybe I'm looking in the wrong places.

Thanks in advance for any help Alan

-1


a source to share


1 answer


I just wanted to give an update on this issue in case it helps anyone else.

I gave up trying to find a direct code entry point for the method the caret is in. This led me to develop an algorithm to parse the code surrounding the carriage position. This was adequate for my own needs and came close to the days of googling for a solution.



Alan

0


a source







All Articles