[Opensource] best use of framework, transitioning
Michael Rimov
rimovm at centercomp.com
Mon Mar 17 22:11:50 PST 2003
At 03:11 PM 3/17/2003 -0600, you wrote:
>I've got one controller-state that needs to switch control to another
>controller-state. I can make that happen with following code:
>
>MyController mycontroller = new MyController();
>Transition newTrans = new Transition("addWizard","stringhere",
>mycontroller.getClass() ,"promptAppeal");
>newTrans.transition(request,response);
>
>however, all of my parameters in the request object disappear. Can I make
>them not disappear easily. Do I need to allocate control to another
>controller differently?
>Am I missing the point of Transitions all together?
Actually, I mandate this behavior because controllers being transitioned to
need to be protected from wayward parameters that may mean one thing for
one controller and another for the next. Thus you need to explicityly
define your objects with either: Transition.addParameter() OR in rare
cases where you really know the target controller, call
Transision.setParams(request.getParameters()); to transfer all parameters
over to the target controller.
HTH!
-Mike
More information about the Opensource
mailing list