|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.goldeninnovations.smp.MessagePart
public class MessagePart
Represents a single message part of a multipart message.
Method Summary | |
---|---|
String |
getAttachmentFilename()
If this MessagePart is an attachment, returns the
name of the attached file. |
String |
getBody()
Returns the body of the message part without any parsing or decoding. |
String |
getContentDescription()
The value of the Content-Description header. |
String |
getContentDisposition()
The value of the Content-Disposition header. |
String |
getContentTransferEncoding()
The value of the Content-Transfer-Encoding header. |
String |
getContentType()
The value of the Content-Type header. |
String |
getHeader(String headerName)
Returns the value of first header found that matches the header name. |
String |
getMimeVersion()
The value of the MIME-Version header. |
boolean |
isAttachment()
True if this MessagePart is an attached file. |
boolean |
writeAttachment(OutputStream outputStream)
Attempts to write the contents of this MessagePart to the specified OutputStream . |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public String getMimeVersion()
public String getContentType()
public String getContentTransferEncoding()
public String getContentDisposition()
public String getContentDescription()
public boolean isAttachment()
public String getAttachmentFilename()
MessagePart
is an attachment, returns the
name of the attached file.
public String getBody()
public String getHeader(String headerName)
headerName
- the name of the header to find.
public boolean writeAttachment(OutputStream outputStream) throws IOException
MessagePart
to the specified OutputStream
.
The contents will be decoded if appropriate and supported. Current encoding supported include:
outputStream
- the stream the decoded contents will be written to.
IOException
- thrown if there is an error writing to the OutputStream
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |