Notice: This Wiki is now read only and edits are no longer possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.
Difference between revisions of "JSDT/JSDT-DOM-and-bindings"
Line 1: | Line 1: | ||
= JSDT DOM and bindings = | = JSDT DOM and bindings = | ||
+ | |||
+ | Starting from Eclipse Oxygen, JSDT parsing is done with ClosureCompiler. | ||
+ | After CC parsing, a converter transforms the CC AST into the JSDT core DOM AST. | ||
+ | Then, we use bindings to consume the DOM model and provide content assist, code completion, etc. | ||
This page explains: the ClosureCompiler AST, the DOM AST and the Bindings to the Eclipse IDE | This page explains: the ClosureCompiler AST, the DOM AST and the Bindings to the Eclipse IDE | ||
− | Other JSDT Architectural information is reported in [https://wiki.eclipse.org/JSDT/Architecture JSDT/Architecture]. | + | Other JSDT Architectural information is reported in the parent page [https://wiki.eclipse.org/JSDT/Architecture JSDT/Architecture]. |
== ClosureCompiler AST == | == ClosureCompiler AST == | ||
− | + | Closure Compiler documentation is mostly in its code. | |
− | To understand it, we should look at the CC source and at the work done when moving JSDT to ClosureCompiler. | + | To understand how it works, we should look at the CC source, at few documentation pages, and at the work done when moving JSDT to ClosureCompiler. |
− | * | + | * Closure Compiler source on GitHub: https://github.com/google/closure-compiler |
− | * | + | * Docs from [https://github.com/google/closure-compiler/wiki CC wiki]: |
+ | like [https://github.com/google/closure-compiler/wiki/Using-the-Compiler's-Java-API using CC Java API], | ||
+ | [https://github.com/google/closure-compiler/wiki/Tutorials CC tutorials], ... | ||
+ | * Adding closure compiler for JSDT parsing: https://git.eclipse.org/r/#/c/92404/ | ||
== DOM AST == | == DOM AST == |
Revision as of 04:40, 6 April 2017
JSDT DOM and bindings
Starting from Eclipse Oxygen, JSDT parsing is done with ClosureCompiler. After CC parsing, a converter transforms the CC AST into the JSDT core DOM AST. Then, we use bindings to consume the DOM model and provide content assist, code completion, etc.
This page explains: the ClosureCompiler AST, the DOM AST and the Bindings to the Eclipse IDE
Other JSDT Architectural information is reported in the parent page JSDT/Architecture.
ClosureCompiler AST
Closure Compiler documentation is mostly in its code. To understand how it works, we should look at the CC source, at few documentation pages, and at the work done when moving JSDT to ClosureCompiler.
- Closure Compiler source on GitHub: https://github.com/google/closure-compiler
- Docs from CC wiki:
like using CC Java API, CC tutorials, ...
- Adding closure compiler for JSDT parsing: https://git.eclipse.org/r/#/c/92404/
DOM AST
The AST class The package org.eclipse.wst.jsdt.core.dom contains the class
This is the AST used in JSDT core. It contains all the information needed to create outline, for content assist etc..
Bindings
This part is about the bindings needed to show the model in the outline, to provide content assist, indexing etc.
Other Notes
See commit https://git.eclipse.org/r/#/c/57504/ (M.Istria) to see the new outline