How can I know the exact meaning of a AST node. #2004
-
I'm developing a custom SQL processor using the visitor pattern. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 4 replies
-
Greetings. I understand what you mean, this kind of documentation is missing:
A strong volunteer would need to write that as Java-Doc into each AST class. |
Beta Was this translation helpful? Give feedback.
-
Additionally you can use JSQLFormatter online to get this kind of AST illustration:
|
Beta Was this translation helpful? Give feedback.
I am sorry to tell you that exactly this kind of documentation is missing, because nobody has the time and resources to write it.
Of course you are most welcome to submit PRs with JavaDoc when you are on this job now.
Btw, IntelliJ has an excellent JavaCC plugin which makes it easy to find the production for each AST class.
Also, you could parse the grammar with javaCC itself to get the BNF of each production and last but not least https://manticore-projects.com/JSQLParser/syntax_snapshot.html will show you the Grammar and has a searchable side bar.
Example for
AllTableColumns
: https://manticore-projects.com/JSQLParser/syntax_snapshot.html#alltablecolumns