| java.lang.Object dtw.webmail.util.MimeBodyPartDataSource
MimeBodyPartDataSource | public class MimeBodyPartDataSource implements DataSource(Code) | | Class that implements a MimeBodyPartDataSource.
It implements DataSource for handling
with the Mail API (or other JAF aware) classes.
author: Dieter Wimberger version: 0.9.7 07/02/2003 |
Constructor Summary | |
public | MimeBodyPartDataSource(String type, String name, byte[] data) Constructs a MimeBodyPartDataSource
instance.
Parameters: type - the content type of the constructed instanceas String. Parameters: name - the name of the constructed instanceas String. Parameters: data - the data of the constructed instance asbyte[]. |
MimeBodyPartDataSource | public MimeBodyPartDataSource(String type, String name, byte[] data)(Code) | | Constructs a MimeBodyPartDataSource
instance.
Parameters: type - the content type of the constructed instanceas String. Parameters: name - the name of the constructed instanceas String. Parameters: data - the data of the constructed instance asbyte[]. the newly constructed MimeBodyPartDataSource. |
getContentType | public String getContentType()(Code) | | Returns the content type of this instance as
String.
(DataSource implementation)
the content type as String |
getInputStream | public InputStream getInputStream() throws IOException(Code) | | Returns the data of this instance as
InputStream.
(DataSource implementation); wraps the data
into a ByteArrayInputStream.
the data of this instance asInputStream. throws: IOException - if impossible. |
getName | public String getName()(Code) | | Returns the name of this instance as String.
(DataSource implementation)
the name as String |
getOutputStream | public OutputStream getOutputStream() throws IOException(Code) | | Throws an IOException in this implementation, because
this instance represents a read-only DataSource.
(DataSource implementation)
an OutputStream instance for writingto this DataSource. throws: IOException - if impossible. |
|
|