public class SmimeDataContentHandler
extends java.lang.Object
implements javax.activation.DataContentHandler
| Constructor and Description |
|---|
SmimeDataContentHandler() |
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
getContent(javax.activation.DataSource ds)
Returns the appropriate
SmimeObject from the DataSource. |
java.lang.Object |
getTransferData(java.awt.datatransfer.DataFlavor flavor,
javax.activation.DataSource source)
Data transfer not supported.
|
java.awt.datatransfer.DataFlavor[] |
getTransferDataFlavors()
Data transfer not supported.
|
void |
writeTo(java.lang.Object obj,
java.lang.String mimeType,
java.io.OutputStream os)
Output the
SmimeObject to the specified output stream. |
public java.awt.datatransfer.DataFlavor[] getTransferDataFlavors()
getTransferDataFlavors in interface javax.activation.DataContentHandlerpublic java.lang.Object getTransferData(java.awt.datatransfer.DataFlavor flavor,
javax.activation.DataSource source)
throws java.awt.datatransfer.UnsupportedFlavorException
getTransferData in interface javax.activation.DataContentHandlerjava.awt.datatransfer.UnsupportedFlavorExceptionpublic java.lang.Object getContent(javax.activation.DataSource ds)
throws java.io.IOException
SmimeObject from the DataSource.
If the content type params for a signed receipt are missing a SmimeSigned is returned.
getContent in interface javax.activation.DataContentHandlerds - The data source.SmimeSigned or SmimeMultipartSigned or SmimeEnveloped or
SmimeSignedReceipt Object.java.io.IOException - If the input is not a S/MIME message or the input encoding is incorrect
or an I/O error occurs.public void writeTo(java.lang.Object obj,
java.lang.String mimeType,
java.io.OutputStream os)
throws java.io.IOException
SmimeObject to the specified output stream.writeTo in interface javax.activation.DataContentHandlerobj - An SmimeObject.mimeType - The mime-type of the SmimeObject.os - The output stream.java.io.IOException - An I/O error occurred or the SmimeObject has not been properly initialized.