Re: I'm stuck - recomended way to pass parameters between chained actions ( WW-1.3 )
Conor MacNeill <[email protected]>
| Newsgroups | gmane.comp.java.open-symphony.devel |
|---|---|
| Message-ID | <[email protected]> |
On Fri, 26 Sep 2003 09:27 pm, Konstantin Priblouda wrote: > --- Joseph Ottinger <[email protected]> wrote: > > Use the valuestack itself. > > > > ActionA would have getThing(). > > ActionB would get the value stack and use > > findValue("thing"). > > That's an option. But if I like the process to be > transparent to chained action? > > Say, first action puts parameter "foo" somewhere > ( request? ) and chained action gets this parameter > set on evecution like it came from real request? > > rehards, > I've had this problem too. I came up with a quick workaround: Map newParams = new HashMap(); newParams.putAll(ActionContext.getContext().getParameters()); newParams.put("foo", value.toString()); ActionContext.getContext().setParameters(newParams); It's a hack and I don't really like it but it did work. In the end I've moved away from chaining except where I don't need to pass info along the chain. Is there a better way to do this? Conor ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf