electric.util.mime
Interface IDataHandler

All Known Implementing Classes:
FileDataHandler, MemoryDataHandler

public interface IDataHandler

IDataHandler defines the operations common to all MIME data handlers.

Author:
webMethods

Method Summary
 boolean dispose()
          Dispose of the content and return true if the operation was success.
 java.io.InputStream getInputStream()
          Return an input stream for reading the MIME data content.
 void readContent(java.io.InputStream input, int length, java.lang.String id, byte[] delimiter, Context context)
          Read the MIME data content and store it for future retrieval.
 

Method Detail

readContent

public void readContent(java.io.InputStream input,
                        int length,
                        java.lang.String id,
                        byte[] delimiter,
                        Context context)
                 throws java.io.IOException
Read the MIME data content and store it for future retrieval.

Parameters:
input - The input stream to read the MIME data content.
length - The size of the content specified by the Content-Length header.
id - The id of the attachment specified by the Content-ID or Content-Location headers.
delimiter - The delimiter of the attachment in the stream. Should be used when length is not set
context - The context of the service or proxy.
Throws:
java.io.IOException

getInputStream

public java.io.InputStream getInputStream()
Return an input stream for reading the MIME data content.


dispose

public boolean dispose()
                throws java.io.IOException
Dispose of the content and return true if the operation was success.

Throws:
java.io.IOException


copyright© 2001-2004 by webMethods All Rights Reserved.