Package org.apache.poi.hmef.extractor
Class HMEFContentsExtractor
- java.lang.Object
-
- org.apache.poi.hmef.extractor.HMEFContentsExtractor
-
public final class HMEFContentsExtractor extends java.lang.ObjectA utility for extracting out the message body, and all attachments from a HMEF/TNEF/winmail.dat file
-
-
Constructor Summary
Constructors Constructor Description HMEFContentsExtractor(java.io.File filename)HMEFContentsExtractor(HMEFMessage message)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidextractAttachments(java.io.File dir)Extracts all the message attachments to the supplied directoryvoidextractMessageBody(java.io.File dest)Extracts the RTF message body to the supplied filevoidextractMessageBody(java.io.OutputStream out)Extracts the RTF message body to the supplied stream.static voidmain(java.lang.String[] args)Usage: HMEFContentsExtractor <filename> <output dir>
-
-
-
Constructor Detail
-
HMEFContentsExtractor
public HMEFContentsExtractor(java.io.File filename) throws java.io.IOException- Throws:
java.io.IOException
-
HMEFContentsExtractor
public HMEFContentsExtractor(HMEFMessage message)
-
-
Method Detail
-
main
public static void main(java.lang.String[] args) throws java.io.IOExceptionUsage: HMEFContentsExtractor <filename> <output dir>- Throws:
java.io.IOException
-
extractMessageBody
public void extractMessageBody(java.io.File dest) throws java.io.IOExceptionExtracts the RTF message body to the supplied file- Throws:
java.io.IOException
-
extractMessageBody
public void extractMessageBody(java.io.OutputStream out) throws java.io.IOExceptionExtracts the RTF message body to the supplied stream. If there is no RTF message body, nothing will be written to the stream, but no errors or exceptions will be raised.- Throws:
java.io.IOException
-
extractAttachments
public void extractAttachments(java.io.File dir) throws java.io.IOExceptionExtracts all the message attachments to the supplied directory- Throws:
java.io.IOException
-
-