Click or drag to resize
MimeKit

MimeEntity Class

An abstract MIME entity.
Inheritance Hierarchy

Namespace:  MimeKit
Assembly:  MimeKit (in MimeKit.dll) Version: 3.0.0
Syntax
C#
public abstract class MimeEntity : IDisposable

The MimeEntity type exposes the following members.

Constructors
  NameDescription
Protected methodMimeEntity(ContentType)
Initialize a new instance of the MimeEntity class.
Protected methodMimeEntity(MimeEntityConstructorArgs)
Initialize a new instance of the MimeEntity class based on the MimeEntityConstructorArgs.
Protected methodMimeEntity(String, String)
Initialize a new instance of the MimeEntity class.
Top
Properties
  NameDescription
Public propertyContentBase
Gets or sets the base content URI.
Public propertyContentDisposition
Gets or sets the content disposition.
Public propertyContentId
Gets or sets the content identifier.
Public propertyContentLocation
Gets or sets the content location.
Public propertyContentType
Gets the type of the content.
Public propertyHeaders
Gets the list of headers.
Public propertyIsAttachment
Gets a value indicating whether this MimePart is an attachment.
Top
Methods
  NameDescription
Public methodAccept
Dispatches to the specific visit method for this MIME entity.
Public methodDispose
Releases all resources used by the MimeEntity object.
Protected methodDispose(Boolean)
Releases the unmanaged resources used by the MimeEntity and optionally releases the managed resources.
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Protected methodFinalize
Releases unmanaged resources and performs other cleanup operations before the MimeEntity is reclaimed by garbage collection.
(Overrides ObjectFinalize.)
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodStatic memberLoad(Stream, CancellationToken)
Load a MimeEntity from the specified stream.
Public methodStatic memberLoad(String, CancellationToken)
Load a MimeEntity from the specified file.
Public methodStatic memberCode exampleLoad(ContentType, Stream, CancellationToken)
Load a MimeEntity from the specified content stream.
Public methodStatic memberLoad(ParserOptions, Stream, CancellationToken)
Load a MimeEntity from the specified stream.
Public methodStatic memberLoad(ParserOptions, String, CancellationToken)
Load a MimeEntity from the specified file.
Public methodStatic memberLoad(Stream, Boolean, CancellationToken)
Load a MimeEntity from the specified stream.
Public methodStatic memberLoad(ParserOptions, ContentType, Stream, CancellationToken)
Load a MimeEntity from the specified content stream.
Public methodStatic memberLoad(ParserOptions, Stream, Boolean, CancellationToken)
Load a MimeEntity from the specified stream.
Public methodStatic memberLoadAsync(Stream, CancellationToken)
Asynchronously load a MimeEntity from the specified stream.
Public methodStatic memberLoadAsync(String, CancellationToken)
Asynchroinously load a MimeEntity from the specified file.
Public methodStatic memberLoadAsync(ContentType, Stream, CancellationToken)
Asynchronously load a MimeEntity from the specified content stream.
Public methodStatic memberLoadAsync(ParserOptions, Stream, CancellationToken)
Asynchronously load a MimeEntity from the specified stream.
Public methodStatic memberLoadAsync(ParserOptions, String, CancellationToken)
Asynchronously load a MimeEntity from the specified file.
Public methodStatic memberLoadAsync(Stream, Boolean, CancellationToken)
Asynchronously load a MimeEntity from the specified stream.
Public methodStatic memberLoadAsync(ParserOptions, ContentType, Stream, CancellationToken)
Asynchronously load a MimeEntity from the specified content stream.
Public methodStatic memberLoadAsync(ParserOptions, Stream, Boolean, CancellationToken)
Asynchronously load a MimeEntity from the specified stream.
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Protected methodOnHeadersChanged
Called when the headers change in some way.
Public methodPrepare
Prepare the MIME entity for transport using the specified encoding constraints.
Protected methodRemoveHeader
Remove a header by name.
Protected methodSetHeader(String, Byte)
Set the value of a header using the raw value.
Protected methodSetHeader(String, String)
Set the value of a header.
Public methodToString
Returns a String that represents the MimeEntity for debugging purposes.
(Overrides ObjectToString.)
Protected methodTryInit
Tries to use the given object to initialize the appropriate property.
Public methodWriteTo(Stream, CancellationToken)
Write the MimeEntity to the specified output stream.
Public methodWriteTo(String, CancellationToken)
Write the MimeEntity to the specified file.
Public methodWriteTo(FormatOptions, Stream, CancellationToken)
Write the MimeEntity to the specified output stream.
Public methodWriteTo(FormatOptions, String, CancellationToken)
Write the MimeEntity to the specified file.
Public methodWriteTo(Stream, Boolean, CancellationToken)
Write the MimeEntity to the specified output stream.
Public methodWriteTo(String, Boolean, CancellationToken)
Write the MimeEntity to the specified file.
Public methodWriteTo(FormatOptions, Stream, Boolean, CancellationToken)
Write the MimeEntity to the specified output stream.
Public methodWriteTo(FormatOptions, String, Boolean, CancellationToken)
Write the MimeEntity to the specified file.
Public methodWriteToAsync(Stream, CancellationToken)
Asynchronously write the MimeEntity to the specified output stream.
Public methodWriteToAsync(String, CancellationToken)
Asynchronously write the MimeEntity to the specified file.
Public methodWriteToAsync(FormatOptions, Stream, CancellationToken)
Asynchronously write the MimeEntity to the specified output stream.
Public methodWriteToAsync(FormatOptions, String, CancellationToken)
Asynchronously write the MimeEntity to the specified file.
Public methodWriteToAsync(Stream, Boolean, CancellationToken)
Asynchronously write the MimeEntity to the specified output stream.
Public methodWriteToAsync(String, Boolean, CancellationToken)
Asynchronously write the MimeEntity to the specified file.
Public methodWriteToAsync(FormatOptions, Stream, Boolean, CancellationToken)
Asynchronously write the MimeEntity to the specified output stream.
Public methodWriteToAsync(FormatOptions, String, Boolean, CancellationToken)
Asynchronously write the MimeEntity to the specified file.
Top
Remarks

A MIME entity is really just a node in a tree structure of MIME parts in a MIME message.

There are 3 basic types of entities: MimePart, Multipart, and MessagePart (which is actually just a special variation of MimePart who's content is another MIME message/document). All other types are derivatives of one of those.

See Also