PHP Parser [message #652205] |
Thu, 03 February 2011 00:18  |
Eclipse User |
|
|
|
Hi,
I'm trying to develop a program for static analysis of PHP scripts. I want to use eclipse internal classes for parsing the file and generating the AST. But I can't find any sort of documentation regarding org.eclipse.php.internal or similar namespaces. For example, I'm trying the following for getting the program constructs:
import org.eclipse.php.internal.core.*;
import org.eclipse.php.internal.core.ast.nodes.AST;
import org.eclipse.php.internal.core.ast.nodes.Program;
...
Reader reader = new FileReader("test.php");
AST a = new AST(reader, PHPVersion.PHP5, true, true);
Program p = new Program(a);
But it simply does nothing. I need a sort of documentation, and article etc about how to use the pdt classes. Any idea?
Alternatively, do you know any other documented Php parser/ast generator in java?
Thanks in advance.
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03127 seconds