I am trying to write a program to analyze Java source code, for example, checking all the callers to some certain method. Since eclipse IDE provides this kind of feature, which is powerful and impressive, I am wondering if they provide some APIs so I can use those features in my program as well.
I checked some materials online. But nearly all of the documents I can find are related with eclipse plug-in development, which is not what I want. I want to use them in a stand-alone program (maybe as part of a compilation chain to do customized style checking).
Is this possible? If so, any link as entrypoint for me to start research would be very appreciated. If not, is there any alternative that I can try?
(I used to think about using ANTLR, but it is merely a parser that is quite a few steps away from a source code analyzer)
I don’t know about Eclipse itself, but here are some alternatives:
First, the relatively lightweight:
These might be overkill, but the heavy guns for Java analysis are Soot from McGill U. and WALA from IBM.