You can use a org.apache.wicket.request.resource.ByteArrayResource
instead - It's an IResource implementation that takes a byte array. You
can then use the resource in a DownloadLink, for example.

Carl-Eric

On Mon, 14 Apr 2014 12:11:06 +0200
<[email protected]> wrote:

> Hello,
> 
> Iam using a FileResourceStream to download a file. This needs an
> File, which I create on the fly like this:
> 
> tempFile = File.createTempFile("SLA", ".xls");
> 
> InputStream data = new
> ByteArrayInputStream(ConsoleDataHandlerImpl.getInstance().getReportAsByteStream(beginDate,endDate));
> Files.writeTo(tempFile, data);
> 
> It works fine. But the problem is that it save the tempfile in my tmp
> folder. Is there a RessourceStream in Wicket which can handle a byte
> array so that I don't need a tempfile?
> 
> 
> Mit freundlichen Grüßen
> Christoph Manig
> 
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to