Can I use the AST / JDT for other languages? for example to write my own parser for C# that uses somehow the AST technology?
If you look at the article "Eclipse JDT - Abstract Syntax Tree (AST) and the Java Model - Tutorial", JDT and its AST are tailored for Java.
The Eclipse Java Development Tools (JDT) provide APIs to access and manipulate Java source code.
The AST is a detailed tree representation of Java source code. The AST defines API to modify, create, read and delete source code.
The package for AST isorg.eclipse.jdt.core.dom
in the Eclipseorg.eclipse.jdt.core
plugin.
Other AST exists for other languages, and for generating your own, you could use XText
But the one in a jdt package is speicialized for Java.
It can be viewed through an ASTView
See also the Exploring Eclipse's ASTParser article as another illustration of the Java-oriented aspect of eclipse AST manipulations.