-1

I am new to multi part data. I need to parse and read body content of multi part data. Following below is my multi part data. To be specific my data is embedded inside a soap message, not sure if it's relevant.

Using Java I intend to parse and get only the content in bold from the below multi part data, as that's my actual data.

Please help. Thanks in Advance

--MIMEBoundary_8589d345264cb1f477a630c11ab99948c31ab3bfccba010e Content-Type: application/xop+xml; charset=UTF-8; type="application/soap+xml" Content-Transfer-Encoding: binary Content-ID: <0.b589d345264cb1f477a630c11ab99948c31ab3bfccba010e@apache.org>

--MIMEBoundary_8589d345264cb1f477a630c11ab99948c31ab3bfccba010e Content-Type: application/octet-stream Content-Transfer-Encoding: binary Content-ID: <1.a589d345264cb1f477a630c11ab99948c31ab3bfccba010e@apache.org>

X5O!P%@AP[4\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H* --MIMEBoundary_8589d345264cb1f477a630c11ab99948c31ab3bfccba010e--

Vinod Jayachandran
  • 3,726
  • 8
  • 51
  • 88

1 Answers1

1

You can do it by creating an instance of multipartReport like

MultipartReport multipartReport = new MultipartReport(mimeMessageInstance.dataHandler.dataSource);

and then get the body part using multipartReport

akashsethi
  • 46
  • 5