In my action class, I have a ByteArrayOutputStream that I want to return as the response to the browser.
I've tried creating a forward and putting this object in the session, but that clearly isn't how you'd do this.
Our action class method doesn't include an HttpServletResponse object as a parameter.
My quick check of an Action method shows that there IS an HttpServletReponse method there.
Can someone give me a suggestion on how to "hook" the response (in
Struts)
from the action class?
Is the best (only) solution to add the HttpServletReponse object to the action's method that handles this request? In our case, our action class that processes the events isn't the "execute" method, but a post process method.
Shouldn't all action classes have access to the HttpServletResponse object?
So, in a nutshell, "How" best would I hook the Byte stream back to the browser without the Response object is my main question.
I'm trying to do this the "Struts" way if using the HttpServletResponse object isn't the "Struts way". (Using the response object works fine, however, if that's the Struts way too).
Thanks much for any suggestions!!!
M