org.apache.servicemix.jbi.util
Class StreamDataSource

java.lang.Object
  extended by org.apache.servicemix.jbi.util.StreamDataSource
All Implemented Interfaces:
DataSource

public class StreamDataSource
extends Object
implements DataSource

Stream DataSource for Mail and message attachments .

Since:
3.0
Author:
Guillaume Nodet

Constructor Summary
StreamDataSource(InputStream in)
           
StreamDataSource(InputStream in, String contentType)
           
StreamDataSource(InputStream in, String contentType, String name)
           
 
Method Summary
 String getContentType()
           
 InputStream getInputStream()
           
 String getName()
           
 OutputStream getOutputStream()
           
 void setContentType(String contentType)
           
 void setName(String name)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StreamDataSource

public StreamDataSource(InputStream in)

StreamDataSource

public StreamDataSource(InputStream in,
                        String contentType)

StreamDataSource

public StreamDataSource(InputStream in,
                        String contentType,
                        String name)
Method Detail

getInputStream

public InputStream getInputStream()
                           throws IOException
Specified by:
getInputStream in interface DataSource
Throws:
IOException

getOutputStream

public OutputStream getOutputStream()
                             throws IOException
Specified by:
getOutputStream in interface DataSource
Throws:
IOException

getContentType

public String getContentType()
Specified by:
getContentType in interface DataSource

getName

public String getName()
Specified by:
getName in interface DataSource

setName

public void setName(String name)

setContentType

public void setContentType(String contentType)


Copyright © 2005-2007 Apache Software Foundation. All Rights Reserved.