Mime4.net Home | Community Edition | Order | Usage examples | Feedback
NI.Email.Mime NamespaceMIME4NET Class Library Documentation
MIME4NET library.
Classes

  ClassDescription
Public classAbstractContentHandler
Abstract ContentHandler with default implementations of all the methods of the ContentHandler interface.
Public classBodyDescriptor
Encapsulates the values of the MIME-specific header fields (which starts with Content-).
Public classCloseShieldStream
InputStream that shields its underlying input stream from being closed.
Public classEOLConvertingInputStream
InputStream which converts \r bytes not followed by \n and \n not preceded by \r to \r\n.
Public classLicenseHelper
Public classMimeBoundaryInputStream
Stream that constrains itself to a single MIME body part. After the stream ends (i.e. read() returns -1) HasMoreParts can be used to determine if a final boundary has been seen or not. If ParentEOF is true an unexpected end of stream has been detected in the parent stream.
Public classMimeStreamParser
Public classRootInputStream
InputStream used by the parser to wrap the original user supplied stream. This stream keeps track of the current line number and can also be truncated. When truncated the stream will appear to have reached end of file. This is used by the parser's Stop  method.
Interfaces

  InterfaceDescription
Public interfaceIContentHandler

Receives notifications of the content of a plain RFC822 or MIME message. Implement this interface and register an instance of that implementation with a MimeStreamParser instance using its {@link org.mime4j.MimeStreamParser#setContentHandler(ContentHandler)} method. The parser uses the ContentHandler instance to report basic message-related events like the start and end of the body of a part in a multipart MIME entity.

Events will be generated in the order the corresponding elements occur in the message stream parsed by the parser. E.g.:

startMessage()
    startHeader()
        field(...)
        field(...)
        ...
    endHeader()
    startMultipart()
        preamble(...)
        startBodyPart()
            startHeader()
                field(...)
                field(...)
                ...
            endHeader()
            body()
        endBodyPart()
        startBodyPart()
            startHeader()
                field(...)
                field(...)
                ...
            endHeader()
            body()
        endBodyPart()
        epilogue(...)
    endMultipart()
endMessage()
The above shows an example of a MIME message consisting of a multipart body containing two body parts.

See MIME RFCs 2045-2049 for more information on the structure of MIME messages and RFC 822 and 2822 for the general structure of Internet mail messages.

Enumerations

  EnumerationDescription
Public enumerationEOLConvertingInputStream BehaviourType