Webflow Style Conventions
Cantor, Scott
cantor.2 at osu.edu
Fri Mar 29 11:10:37 EDT 2013
On 3/29/13 10:59 AM, "Marvin Addison" <marvin.addison at gmail.com> wrote:
>Scott's work on Webflow and the action item on today's dev call re
>Webflow prompted me to encourage adopting some style conventions for
>flow XML files.
As somebody more versed in web flow, does anything I wrote make sense?
It's making sense to me coding it up so far, and I don't see why it will
be impossible to essentially turn any POJO following some simple
conventions into an action with a single adaptor object.
What I realized I'm really proposing is to change the inconsistency of
using the BaseContext tree for some state information and parameters
passed around methods like doExecute for other state information. Using
context types to carry Spring and Servlet-specific objects and then making
any dependencies on those technologies an internal detail of action POJOs
is what I'm after.
My plan for the adaptor class is to have it just mechanically:
- populate Spring and Servlet context children
- call execute() on a POJO
- catch any exceptions and translate to Events using some algorithm we
define
- look for an EventContext afterward with String or Event typed content
and return a webflow Event
I think if we do that, every action class in the system is only
Spring-aware if it relies on the Spring context for something. It won't be
in the class hierarchy in any method parameter, and most of them can be
moved into OpenSAML or to any package as we choose.
-- Scott
More information about the dev
mailing list