Really I think the xdoclet jsf plugin is a good example of how to put those navigation rules in the code in a simple and useful way (even it it's not always the right solution). And for me any many other it did the job well.
The annotations plugin we wrote and we propose to commit to a "sandbox 1.5" was ment at first to replace the jsf xdoclet plugin with an annotations plugin as it's quite hard to get this xdoclet plugin work with maven 2.
And it turns out that it works quite nicely, with the additional benefit of some kind of type safety over xdoclet. It's also much faster than the xdoclet plugin.
So my suggestion would be to start from this, and then to enhance it for those that would need more out this plugin.
On Wed, 2006-03-29 at 19:26 +0200, Werner Punz wrote:
Sylvain Vieujot schrieb: > I don't think we should rule out the use of annotations for navigation > rules. > Even if navigation rules are tied to the presentation layer, so are bean > names. > Actually I do not think there is a need for that. There is a more elegant solution to the problem, than using annotations. Implicit nav handling, that could be done without even having to touch annotations or breaking anything. I will give an example usually you have a nav handler with a from outcode ... navigate to... structure well what would happen if we would have a basic automatic outcome to ... mapping mechanism easily doable with a custom navhandler, which then can be overridden by navigational entries. What I am talking here is something along the lines: void doAction() { ... return "mainPage" } without any mapping would route into something like /mainPage.jsf and something like void doAction() { ... return "submodule/detailPage" } would route implicitely into /submodule/detailPage.jsp if you then want to override this behavior, set a custom nav entry for mainPage and for submodule/detailPage the way it used to be. This is way more elegant than using annotations for such a thing.