[Opensource] ControllerResponse.getStyle()
Michael Rimov
rimovm at centercomp.com
Wed Nov 20 12:29:15 PST 2002
At 10:28 AM 11/20/2002 -0500, you wrote:
>Finally had a chance to do some debugging. Setting up a couple of break
>points and I found that setting the style in one state was not present
>in the next state when I used the transition("whatEverState", param,
>response) method.
>
>Any thoughts on how I can keep that style variable set? I thought that
>the response object in the first state was the same response object in
>the state that I transitioned to.
Ok, now I'm following you... I didn't get that you were transitioning
first. The reason we had to clear the style in the transition() method was
because transition often meant a new 'jsp' was going to be used to render
the output.
So if you had the chain of command:
transition(state1) --> transition(state2) --> transition(state3)
You'd want the default style of state3 since that is where the main
inputs/outputs/transitions would be generated.
Ok, so that's why, not let's talk about a workaround.
One posibility is to have the following in your state handler:
String myStyle = whateverStyleIWant;
....
transition("newState", blah blah blah);
response.setStyle(myStyle);
return;
Would that work for you?
-Mike
More information about the Opensource
mailing list