child.setEncodingAndType(contentType);// Parse the content-type
if (isStoreMimeMessage()) {
// Don't save headers - they are already in the raw message
ByteArrayOutputStream bout = new ByteArrayOutputStream();
message.writeTo(bout);
child.setResponseData(bout.toByteArray()); // Save raw message
child.setDataType(SampleResult.TEXT);
} else {
@SuppressWarnings("unchecked") // Javadoc for the API says this is OK
Enumeration<Header> hdrs = message.getAllHeaders();