com.openexchange.mail.mime.datasource
Interface StreamDataSource.InputStreamProvider

Enclosing class:
StreamDataSource

public static interface StreamDataSource.InputStreamProvider

Provides a newly allocated input stream.


Method Summary
 java.io.InputStream getInputStream()
          Gets a newly allocated input stream.
 java.lang.String getName()
          Gets an appropriate name for the resource providing the input stream.
 

Method Detail

getInputStream

java.io.InputStream getInputStream()
                                   throws java.io.IOException
Gets a newly allocated input stream.

This method returns an InputStream representing the data and throws the appropriate exception if it can not do so.
NOTE: A new InputStream object must be returned each time this method is called, and the stream must be positioned at the beginning of the data.

Returns:
A newly allocated input stream
Throws:
java.io.IOException - If an I/O error occurs when allocating a new input stream.

getName

java.lang.String getName()
Gets an appropriate name for the resource providing the input stream.

Returns:
An appropriate name for the resource providing the input stream