On 11/10/05, Sean Schofield <[EMAIL PROTECTED]> wrote:
>
> I know this conversation was over a week ago but I finally had some
> time to get back to my mailing list backlog... (see inline comments
> below)
>
> > How is this different from just encapsulating your setup logic into an
> > action method, and then calling it as the first state of the dialog
> > explicitly? Besides the readability value of explicit declaration, and
> the
> > simplicity of not having to learn yet another concept to do this kind of
> > thing, this would also give you the opportunity to transition
> differently
> > based on outcomes from the setup state.
>
> I suppose we could have
>
> <action name="Import Wizard State" method='#{
> wizardHelper.importWizardState}">
> <transition outcome="next" target="First Real Step"/>
> </action>
>
> for every dialog. It just adds 3 lines of XML for every single
> dialog. Kind of a pain.


Is it really more painful than adding a prestartMethod="#{
wizardHelper.importWizardState}" attribute to the <dialog> element?

Especially considering that doing it this way means (a) no new concept to
learn, and (b) you can transition different directions if, say, your
database connection is down and you can't acquire the resources that you
need.

> If the logic to set up a dialog was common across multiple dialogs, you
> > could easily point at a common method in some utility managed bean, so
> you
> > only had to code the server side setup once.
>
> I believe that is what we are already doing. See the wizard "helper"
> bean in the above example. Is this what you mean?


Yes.

Anyways, just bouncing an idea around. I thought it might be too
> application specific. Perhaps other users will have similar needs and
> we can revisit it at that time.
>
> > Craig
>
> sean


Craig

Reply via email to