D
Douglas Dillon
I've inherited a Servlet that produces a jpg and displays it in a
browser. I've been asked to change it to have the output saved to a
location specified by the Client.
It's quite simple at the moment
private void outputJPEG(BufferedImage field, HttpServletResponse res,
ServletOutputStream os)
throws IOException
{
res.setContentType("image/jpeg");
ImageIO.write(field, "jpeg", os);
}
Is there a simple way to prompt the user for a file and pipe the
BufferedImage to it?
Thanks
Douglas
browser. I've been asked to change it to have the output saved to a
location specified by the Client.
It's quite simple at the moment
private void outputJPEG(BufferedImage field, HttpServletResponse res,
ServletOutputStream os)
throws IOException
{
res.setContentType("image/jpeg");
ImageIO.write(field, "jpeg", os);
}
Is there a simple way to prompt the user for a file and pipe the
BufferedImage to it?
Thanks
Douglas