Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[jdt-core-dev] Questions about the new ReconcileContext API


I filed this as bug 129998, but Jerome preferred that I bring these issues on the mailing list.

The API of ReconcileContext contains:

- getASTLevel
and
- getAST3

As getAST3 says, the only ast you get is always of level 3. So why is there a
method 'getASTLevel' then?

And why are we forcing ourselves to only return AST level 3? What if we do an
AST level 4 one time?

A much better API would have been to have a getAST() and spec'ing that the
level will be the 'latest' level and all participants have to first check if
they can deal with this level, or not participate otherwise.
That way a API 'getASTLevel' makes sense again so that clients can first ask
what the 'latest' level is without potentially creating any AST.


Martin

Back to the top