org.apache.james.core
Class MimeMessageSource

java.lang.Object
  |
  +--org.apache.james.core.MimeMessageSource
Direct Known Subclasses:
MimeMessageAvalonSource, MimeMessageInputStreamSource, MimeMessageJDBCSource

public abstract class MimeMessageSource
extends java.lang.Object

This defines a reusable datasource that can supply an input stream with MimeMessage data. This allows a MimeMessageWrapper or other classes to grab the underlying data.

See Also:
MimeMessageWrapper

Constructor Summary
MimeMessageSource()
           
 
Method Summary
abstract  java.io.InputStream getInputStream()
          Return an input stream to the data
 long getMessageSize()
          Return the size of all the data.
abstract  java.lang.String getSourceId()
          Returns a unique String ID that represents where this file is loaded from.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MimeMessageSource

public MimeMessageSource()
Method Detail

getSourceId

public abstract java.lang.String getSourceId()
Returns a unique String ID that represents where this file is loaded from. This will be used to identify where the data is, primarily to avoid situations where this data would get overwritten.


getInputStream

public abstract java.io.InputStream getInputStream()
                                            throws java.io.IOException
Return an input stream to the data

java.io.IOException

getMessageSize

public long getMessageSize()
                    throws java.io.IOException
Return the size of all the data. Default implementation... others can override to do this much faster

java.io.IOException


"Copyright © 2001 Apache Jakarta Project. All Rights Reserved."