Anders Engström wrote:
That sounds resonable, when you put it that way. Am I correct in my
assumption that you can return your own 'result' from an action - it
doesn't have to be 'error', 'success' etc. to map the result
string to a view?
Yes, we just predefined a couple that seemed common. But you can return
anything, as long as you match 'em with corresponding view mappings.
About exceptions - Looking at GenericDispatcher is seems that
RuntimeException & Co are never trapped when thrown from
Action.execute() (in GenericDispatcher.executeAction()).
try
{
result = action.execute();
} catch(Exception e)
{
actionException = e;
return;
}
If a RuntimeException is thrown in Action.execute() it will propagate
all the way up to the caller (if using WW in a servlet container, the
servlet container would handle the Throwable - and ServletDispatcher's
pretty error page will not be shown).
Is this the way it is supposed to work - or should GenericDispatcher and
ActionResult actually handle Throwable instead of Exception?
I think you just found a bug :-)
/Rickard
--
Rickard Öberg
[EMAIL PROTECTED]
Senselogic
Got blog? I do. http://dreambean.com
-------------------------------------------------------
This SF.net email is sponsored by: SlickEdit Inc. Develop an edge.
The most comprehensive and flexible code editor you can use.
Code faster. C/C++, C#, Java, HTML, XML, many more. FREE 30-Day Trial.
www.slickedit.com/sourceforge
_______________________________________________
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork