Please ask this question on the Struts user mailing this; the Struts dev list is for the development of Struts itself.
http://struts.apache.org/mail.html Nils-H On Fri, Jan 16, 2009 at 7:26 PM, Miguel <miguel...@gmail.com> wrote: > Hello, > I have a little problema using a Stream Result. I don't understand how > to write to an InputStream, I've seen the solution using the > StringBufferInputStream but that is deprecated and if the content is > big, it may be a memory problem. > So I have 2 questions: how to use the stream result without making a > big string first (it's not streaming), and the second, How about to > pass the action an output stream instead of an input stream? > > I have made a trial with this: > > class ... { > ... > protected InputStream inputStream; > > public InputStream getInputStream() { > return inputStream; > } > > public void setInputStream(InputStream inputStream) { > this.inputStream = inputStream; > } > > public String exportProjectDataAsXml(){ > PipedOutputStream os = new PipedOutputStream(); > PipedInputStream is = new PipedInputStream(os); > BufferedInputStream is2 = new BufferedInputStream (is); > inputStream = is2; > exportSvc.exportProject(project, os); > return "exportxml"; > } > } > > but the data is lost somewhere in the pipes, I think > Does anybody know how to make it work? > Thanks > > Si quieres ser más positivo, pierde un electrón > Miguel Ruiz Velasco S. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org > For additional commands, e-mail: dev-h...@struts.apache.org > > --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org For additional commands, e-mail: dev-h...@struts.apache.org