Jump to: navigation, search

Difference between revisions of "JSDT/Development"

(Developing JSDT)
(JSDT packages)
Line 26: Line 26:
 
* sourceediting/tests/org.eclipse.wst.jsdt.core.tests.model - (test suite is org.eclipse.wst.jsdt.core.tests.model.AllJavaModelTests)
 
* sourceediting/tests/org.eclipse.wst.jsdt.core.tests.model - (test suite is org.eclipse.wst.jsdt.core.tests.model.AllJavaModelTests)
  
== JSDT packages ==  
+
== JSDT packages ==
 +
 
 +
=== JSDT Core ===
 +
The JSDT core plugin (org.eclipse.wst.jsdt.core) provides the core JavaScript modeling.
 +
 
 +
 
 +
{| border="1"
 +
|+ Core plugin packages
 +
! package !! function
 +
|-
 +
! org.eclipse.wst.jsdt.core
 +
| public apis for the modle
 +
|-
 +
! org.eclipse.wst.jsdt.core.ast
 +
| The public apis for the read-only AST used by inference engines
 +
|-
 +
! org.eclipse.wst.jsdt.core.compiler
 +
| the public apis for the validator
 +
|-
 +
! org.eclipse.wst.jsdt.core.compiler.libraries
 +
| libraries which define the javascript language apis and the browser DOM apis
 +
|-
 +
! org.eclipse.wst.jsdt.core.dom
 +
| Modifiable JavaScript model DOM
 +
|-
 +
! org.eclipse.wst.jsdt.core.dom.rewrite
 +
| support for updating the dom
 +
|-
 +
! org.eclipse.wst.jsdt.core.eval
 +
| support for evaluating code fragments
 +
|-
 +
! org.eclipse.wst.jsdt.core.formatter
 +
| public apis for javascript formatting
 +
|-
 +
! org.eclipse.wst.jsdt.core.infer
 +
| support for inferencing and inferencing extensions
 +
|-
 +
! org.eclipse.wst.jsdt.core.search
 +
| public apis for search
 +
|-
 +
! org.eclipse.wst.jsdt.core.util
 +
| public utility apis
 +
|-
 +
! org.eclipse.wst.jsdt.internal.codeassist
 +
| support for code assist and selection
 +
|-
 +
! org.eclipse.wst.jsdt.internal.codeassist.complete
 +
| support for code assist
 +
|-
 +
! org.eclipse.wst.jsdt.internal.codeassist.impl
 +
| support for code assist
 +
|-
 +
! org.eclipse.wst.jsdt.internal.codeassist.select
 +
| support for code selection
 +
|-
 +
! org.eclipse.wst.jsdt.internal.compiler
 +
| validation code
 +
|-
 +
! org.eclipse.wst.jsdt.internal.compiler.ast
 +
| internal javascript AST (Abstract Syntax Tree)
 +
|-
 +
! org.eclipse.wst.jsdt.internal.compiler.batch
 +
| support for batch validation
 +
|-
 +
! org.eclipse.wst.jsdt.internal.compiler.classfmt
 +
| ??
 +
|-
 +
! org.eclipse.wst.jsdt.internal.compiler.env
 +
| ??
 +
|-
 +
! org.eclipse.wst.jsdt.internal.compiler.flow
 +
| support for analyzing code flow for unused vars, etc
 +
|-
 +
! org.eclipse.wst.jsdt.internal.compiler.impl
 +
| implementation of public apis
 +
|-
 +
! org.eclipse.wst.jsdt.internal.compiler.lookup
 +
| support for resolving var/function references
 +
|-
 +
! org.eclipse.wst.jsdt.internal.compiler.parser
 +
| the parser
 +
|-
 +
! org.eclipse.wst.jsdt.internal.compiler.parser.diagnose
 +
| the diagnose parser used when there are syntax errors
 +
|-
 +
! org.eclipse.wst.jsdt.internal.compiler.problem
 +
| support for problem messages
 +
|-
 +
! org.eclipse.wst.jsdt.internal.compiler.util
 +
| parser/validator utilities
 +
|-
 +
! org.eclipse.wst.jsdt.internal.core
 +
| implementation of public apis
 +
|-
 +
! org.eclipse.wst.jsdt.internal.core.builder
 +
| implementation of eclipse builder extension
 +
|-
 +
! org.eclipse.wst.jsdt.internal.core.dom.rewrite
 +
| support for updating code on DOM changes
 +
|-
 +
! org.eclipse.wst.jsdt.internal.core.hierarchy
 +
| support for generating class hierarchy
 +
|-
 +
! org.eclipse.wst.jsdt.internal.core.index
 +
| support for indexing the model, used by search
 +
|-
 +
! org.eclipse.wst.jsdt.internal.core.interpret
 +
| javascript interpreter - under development , currently not used
 +
|-
 +
! org.eclipse.wst.jsdt.internal.core.interpret.builtin
 +
| implementation of javascript language functions used by interpreter
 +
|-
 +
! org.eclipse.wst.jsdt.internal.core.search
 +
| searching functions
 +
|-
 +
! org.eclipse.wst.jsdt.internal.core.search.indexing
 +
| indexing of javascript
 +
|-
 +
! org.eclipse.wst.jsdt.internal.core.search.matching
 +
| functions to determine if possible search match is exact match
 +
|-
 +
! org.eclipse.wst.jsdt.internal.core.search.processing
 +
| search
 +
|-
 +
! org.eclipse.wst.jsdt.internal.core.util
 +
| internal utilities
 +
|-
 +
! org.eclipse.wst.jsdt.internal.formatter
 +
| formatter implementation
 +
|-
 +
! org.eclipse.wst.jsdt.internal.formatter.align
 +
| formatter implementation
 +
|-
 +
! org.eclipse.wst.jsdt.internal.formatter.comment
 +
| comment formatter implementation
 +
|-
 +
! org.eclipse.wst.jsdt.internal.oaametadata
 +
| support for OpenAjax metadata
 +
|-
 +
! org.eclipse.wst.jsdt.launching
 +
| misc utilities
 +
|-
 +
! org.eclipse.wst.jsdt.libraries
 +
| Library support
 +
|}
  
 
== Generating the parser ==
 
== Generating the parser ==
 
Follow the instructions at http://www.eclipse.org/jdt/core/howto/generate%20parser/generateParser.html for generating the parser.  The parser grammer file is located in cvs at sourceediting/plugins/org.eclipse.wst.jsdt.core/grammer/js.g
 
Follow the instructions at http://www.eclipse.org/jdt/core/howto/generate%20parser/generateParser.html for generating the parser.  The parser grammer file is located in cvs at sourceediting/plugins/org.eclipse.wst.jsdt.core/grammer/js.g

Revision as of 13:02, 31 October 2008

Developing JSDT

JSDT Source

The source for JSDT is in the Web Tools project (repository path /cvsroot/webtools).

The following plugin projects provide the core JavaScript editing:

  • sourceediting/plugins/org.eclipse.wst.jsdt.core
  • sourceediting/plugins/org.eclipse.wst.jsdt.manipulation
  • sourceediting/plugins/org.eclipse.wst.jsdt.ui

These plugins have no dependencies other than the Eclipse base (they dont depend on any WebTools). Using these plugins, a javascript project can be created.

The feature project for these is:

  • sourceediting/features/org.eclipse.wst.jsdt.feature


The following plugin projects provide JSDT integration with WebTools, and provide support for javascript within HTML and JSP:

  • sourceediting/plugins/org.eclipse.wst.jsdt.web.core
  • sourceediting/plugins/org.eclipse.wst.jsdt.web.support.jsp
  • sourceediting/plugins/org.eclipse.wst.jsdt.web.ui

The feature project for these is:

  • sourceediting/features/org.eclipse.wst.jsdt.web.feature

The following are the junits for JSDT:

  • sourceediting/tests/org.eclipse.wst.jsdt.core.tests.compiler - (test suite is org.eclipse.wst.jsdt.core.tests.compiler.JSDTTestAll)
  • sourceediting/tests/org.eclipse.wst.jsdt.core.tests.model - (test suite is org.eclipse.wst.jsdt.core.tests.model.AllJavaModelTests)

JSDT packages

JSDT Core

The JSDT core plugin (org.eclipse.wst.jsdt.core) provides the core JavaScript modeling.


Core plugin packages
package function
org.eclipse.wst.jsdt.core public apis for the modle
org.eclipse.wst.jsdt.core.ast The public apis for the read-only AST used by inference engines
org.eclipse.wst.jsdt.core.compiler the public apis for the validator
org.eclipse.wst.jsdt.core.compiler.libraries libraries which define the javascript language apis and the browser DOM apis
org.eclipse.wst.jsdt.core.dom Modifiable JavaScript model DOM
org.eclipse.wst.jsdt.core.dom.rewrite support for updating the dom
org.eclipse.wst.jsdt.core.eval support for evaluating code fragments
org.eclipse.wst.jsdt.core.formatter public apis for javascript formatting
org.eclipse.wst.jsdt.core.infer support for inferencing and inferencing extensions
org.eclipse.wst.jsdt.core.search public apis for search
org.eclipse.wst.jsdt.core.util public utility apis
org.eclipse.wst.jsdt.internal.codeassist support for code assist and selection
org.eclipse.wst.jsdt.internal.codeassist.complete support for code assist
org.eclipse.wst.jsdt.internal.codeassist.impl support for code assist
org.eclipse.wst.jsdt.internal.codeassist.select support for code selection
org.eclipse.wst.jsdt.internal.compiler validation code
org.eclipse.wst.jsdt.internal.compiler.ast internal javascript AST (Abstract Syntax Tree)
org.eclipse.wst.jsdt.internal.compiler.batch support for batch validation
org.eclipse.wst.jsdt.internal.compiler.classfmt  ??
org.eclipse.wst.jsdt.internal.compiler.env  ??
org.eclipse.wst.jsdt.internal.compiler.flow support for analyzing code flow for unused vars, etc
org.eclipse.wst.jsdt.internal.compiler.impl implementation of public apis
org.eclipse.wst.jsdt.internal.compiler.lookup support for resolving var/function references
org.eclipse.wst.jsdt.internal.compiler.parser the parser
org.eclipse.wst.jsdt.internal.compiler.parser.diagnose the diagnose parser used when there are syntax errors
org.eclipse.wst.jsdt.internal.compiler.problem support for problem messages
org.eclipse.wst.jsdt.internal.compiler.util parser/validator utilities
org.eclipse.wst.jsdt.internal.core implementation of public apis
org.eclipse.wst.jsdt.internal.core.builder implementation of eclipse builder extension
org.eclipse.wst.jsdt.internal.core.dom.rewrite support for updating code on DOM changes
org.eclipse.wst.jsdt.internal.core.hierarchy support for generating class hierarchy
org.eclipse.wst.jsdt.internal.core.index support for indexing the model, used by search
org.eclipse.wst.jsdt.internal.core.interpret javascript interpreter - under development , currently not used
org.eclipse.wst.jsdt.internal.core.interpret.builtin implementation of javascript language functions used by interpreter
org.eclipse.wst.jsdt.internal.core.search searching functions
org.eclipse.wst.jsdt.internal.core.search.indexing indexing of javascript
org.eclipse.wst.jsdt.internal.core.search.matching functions to determine if possible search match is exact match
org.eclipse.wst.jsdt.internal.core.search.processing search
org.eclipse.wst.jsdt.internal.core.util internal utilities
org.eclipse.wst.jsdt.internal.formatter formatter implementation
org.eclipse.wst.jsdt.internal.formatter.align formatter implementation
org.eclipse.wst.jsdt.internal.formatter.comment comment formatter implementation
org.eclipse.wst.jsdt.internal.oaametadata support for OpenAjax metadata
org.eclipse.wst.jsdt.launching misc utilities
org.eclipse.wst.jsdt.libraries Library support

Generating the parser

Follow the instructions at http://www.eclipse.org/jdt/core/howto/generate%20parser/generateParser.html for generating the parser. The parser grammer file is located in cvs at sourceediting/plugins/org.eclipse.wst.jsdt.core/grammer/js.g