Ted,
Thanks for the explanation, worked like a champ...I am on my way to exorcising the business logic demons out of my DispatchAction classes!

Dan McGowan


Excellent question! The Scaffold solution is to use a ProcessResult
object that encapsulates the typical things that the Model might want to
send back to the Controller/View. So far, it can transfer data, a
numeric code, messages, a dispatch instruction, along with a name and a
scope.

If the ProcessAction sees that the ProcessResult contains messages, it
converts those to ActionMessages. If it sees it contains data, it expose
that data under the given name and scope. And so forth.

ProcessAction uses a very simple message format. It's just a list where
the first entry is the template key and everything else is replacement
parameters. Easy to build, but you can only send back one message.

Now that we have a Message object in the Commons, I'm migrating a new
version of ProcessResult/ProcessAction to use the Commons Messaging.
But, the basic design pattern remains the same.

HTH, Ted.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to