This discussion is archived
3 Replies Latest reply: Oct 22, 2010 3:23 PM by 807565 RSS

Creating AST from source code in java

843810 Newbie
Currently Being Moderated

Anyone know how to use the new Java Compiler API (or Tree API) to generate a AST from source-code that I can walk and i count no of IF or FOR in given java source file.

i have found threads relating to this but i need more information as i need to count no of IF statements in file.

Thank you.