[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
|
[news.eclipse.tools] Rendering of CompilationUnit
|
Hi,
I'm seaking a way to render the content of a CompilationUnit from the
org.eclipse.jdt.core.dom package. Is there a way to transform it in pretty
source code?
I got the CompilationUnit with the AST-parser, changed it a bit and wanted
to write it back to the original IJavaElement. But I can not find a way to
do that.
Can anyone help?
SourceType source = ... // coming from somewhere
ICompilationUnit iUnit = source.getCompilationUnit();
CompilationUnit unit = AST.parseCompilationUnit(iUnit, false);
... // working on unit
// unit -> source
Thanks,
Gregor