Rick,

It sounds like you are having a problem that I solved last week. I did not get
in on the beginning of this conversation so I will give you a rough draft of
what I did and you can ask me for my code if it will help your situation.

I had a situation where I needed to include the result of other actions in the
middle of my ActionClass so I implement HttpServletRequestWrapper and
HttpServletResponseWrapper so that I could provide RequestDispatcher with a
place to store and retrieve variables from the request scope. In my action
class I swapped the real request and response for the wrapped ones and copied
all the request.getParmeters() and so on into a Hashtable in my wrapper
classes. When I called dispatch.include(req,res) the new action.do was able to
function as if I forwarded control to the new action class. In order to
retrieve the output buffer coming back I created one in my response wrapper
using a String buffer so that I could get at with the toString method. 

This is all open source code, so if any of it sounds useful just ask and I
will send it to you.

Bryan LaPlante

---------- Original Message -----------
From: Rick Reumann <[EMAIL PROTECTED]>
To: Struts Users Mailing List <user@struts.apache.org>
Sent: Fri, 24 Feb 2006 21:41:11 -0500
Subject: Re: passing objects from one request to another

> Jim Reynolds wrote:
> > 
> > IMOHO it is best to stay away from session information unless it is
> > something that is necessary for the full site.
> 
> imo, the Session is better than using hidden variables. People freak out 
> over using the Session like it's something taboo.  If it's a trade off 
> between complicating my app or using the Session - I'd vote for using 
> the Session every time.
> 
> -- 
> Rick
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
------- End of Original Message -------

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to