See Ted's recent post copied in below... I'm definitely going to look at Chain before I invest a lot of energy in a PageController that works as earlier discussions have gone.
So, just to report back. I tried using view Command in place of view action. It worked fairly well at first. You end up with a number of Chains terminating in a view Command, which is fine under most circumstances. Though, it starts to get clumsy when you are bridging between flows, say from a "insert" flow to a "display detail" flow. So, I've gone back to using a view action again. Though, there's only one class that is passed the Command name as a parameter. So the view action just runs a view Command.
Some frameworks, like Maverick, directly supports the notion of a page controller with its own extension point. This seems like a useful strategy for Struts to consider.
The conflicting issues seem to be
* We do want to give ActionForward an extension point so that it can prepare the request before forwarding to its resource.
* We don't want to confuse matters by introducing another navigational decision point. Once the Action has selected an ActionForward, that ActionForward should be responsible for the response.
* We don't necessarily want to introduce another class into the mix.
A side issue is that it would be helpful if the framework provided better support for selecting alternate paths for an ActionForward, based on Locale or other properties ("/pages/en/this.jsp" vs "/pages/fr/this.jsp").
So, in addition to preparing the request, the ActionForward extension point might also want to adjust the path (or choose between paths provided in the configuration).
No concrete proposal; I just wanted to keep this on the table.
-Ted.
-- Ted Husted, Junit in Action - <http://www.manning.com/massol/>, Struts in Action - <http://husted.com/struts/book.html>, JSP Site Design - <http://www.amazon.com/exec/obidos/ISBN=1861005512>.
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]