…
// This exampleassumes that the output format is JPG.
//ProcessImage.getPages() returns an array of byte arrays. Each byte array is onepage.
if (report instanceofProcessImage) {
ProcessImage procImage = (ProcessImage)report;
if (procImage.getPages() != null) {
for (int i = 0; i
byte[] page =procImage.getPages().get(i);
String filename ="outputImage_" + Integer.toString(i) + ".jpg";
FileOutputStream stream = newFileOutputStream(filename);
stream.write(page);
System.out.println("HTML pagewritten to " + filename);
stream.close();
}
}
}
…