Top Description Fields Constructors Methods
jakarta.activation

pack-priv Class DataHandlerDataSource

Located in compilation unit of jakarta.activation.DataHandler.

extends Object
implements DataSource
Class Inheritance
All Implemented Interfaces
jakarta.activation.DataSource

The DataHanderDataSource class implements the DataSource interface when the DataHandler is constructed with an Object and a mimeType string.

Field Summary

Modifier and TypeField and Description
pack-priv DataHandler

Constructor Summary

AccessConstructor and Description
public
DataHandlerDataSource(DataHandler dh)

The constructor.

Method Summary

Modifier and TypeMethod and Description
public String

Returns:

the MIME type
getContentType
()

Implements jakarta.activation.DataSource.getContentType.

Returns the MIME type of the data represented by this object.
public InputStream

Returns:

the InputStream
getInputStream
()

Implements jakarta.activation.DataSource.getInputStream.

Returns an InputStream representing this object.
public String

Returns:

the name of this object
getName
()

Implements jakarta.activation.DataSource.getName.

Returns the name of this object.
public OutputStream

Returns:

the OutputStream
getOutputStream
()

Implements jakarta.activation.DataSource.getOutputStream.

Returns the OutputStream for this object.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

dataHandlerback to summary
pack-priv DataHandler dataHandler

Constructor Detail

DataHandlerDataSourceback to summary
public DataHandlerDataSource(DataHandler dh)

The constructor.

Method Detail

getContentTypeback to summary
public String getContentType()

Implements jakarta.activation.DataSource.getContentType.

Returns the MIME type of the data represented by this object.

Returns:String

the MIME type

getInputStreamback to summary
public InputStream getInputStream() throws IOException

Implements jakarta.activation.DataSource.getInputStream.

Returns an InputStream representing this object.

Returns:InputStream

the InputStream

Exceptions
IOException:

Doc from jakarta.activation.DataSource.getInputStream.

for failures creating the InputStream

getNameback to summary
public String getName()

Implements jakarta.activation.DataSource.getName.

Returns the name of this object.

Returns:String

the name of this object

getOutputStreamback to summary
public OutputStream getOutputStream() throws IOException

Implements jakarta.activation.DataSource.getOutputStream.

Returns the OutputStream for this object.

Returns:OutputStream

the OutputStream

Exceptions
IOException:

Doc from jakarta.activation.DataSource.getOutputStream.

for failures creating the OutputStream