private byte[] createPngImage() throws UnsupportedEncoderException, IOException
{
final ImageEncoder imageEncoder = ImageEncoderRegistry.getInstance().createEncoder(mimeType);
assertNotNull(imageEncoder);
final ByteArrayOutputStream bout = new ByteArrayOutputStream();
imageEncoder.encodeImage(new BufferedImage(10, 10, BufferedImage.TYPE_INT_ARGB), bout, 0.75f, false);
return bout.toByteArray();
}
}