Received Class
A parsed representation of the Received header.
Definition
Namespace: MimeKit
Assembly: MimeKit.Core (in MimeKit.Core.dll) Version: 5.0.0
Assembly: MimeKit.Core (in MimeKit.Core.dll) Version: 5.0.0
C#
public class Received- Inheritance
- Object Received
Remarks
The Received header is used for tracing the path a message has taken through various SMTP servers as it is transmitted from sender to recipient. Each SMTP server that handles the message adds a new Received header to the top of the message, creating a chronological trace of the message's journey through the email infrastructure.
A typical Received header contains several clauses that provide information about the message transfer, including:
- from - the name of the sending host
- by - the name of the receiving host
- via - the physical link or protocol used
- with - the mail protocol used (e.g., SMTP, ESMTP, etc.)
- id - a unique identifier for the message
- for - the recipient address
For more information, see section 4.4 of RFC 5321.
Constructors
| Received | Initializes a new instance of the Received class. |
| Received(String, IPAddress, String, IPAddress, DateTimeOffset) | Initializes a new instance of the Received class. |
Properties
| By | Get or set the name of the receiving host. |
| ByTcpInfo | Get or set the TCP connection information for the receiving host. |
| Clauses | Get the collection of clauses that make up the Received header. |
| DateTime | Get or set the date and time when the message was received. |
| For | Get or set the recipient address for which the message was received. |
| From | Get or set the name of the source host. |
| FromTcpInfo | Get or set the TCP connection information for the source host. |
| Id | Get or set the message identifier. |
| Via | Get or set the physical link or protocol used to receive the message. |
| With | Get or set the protocol or mechanism used to receive the message. |
Methods
| Equals | Determines whether the specified object is equal to the current object. (Inherited from Object) |
| Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object) |
| GetHashCode | Serves as the default hash function. (Inherited from Object) |
| GetType | Gets the Type of the current instance. (Inherited from Object) |
| MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object) |
| Parse(Byte) | Parse the specified input buffer into a new Received instance. |
| Parse(ParserOptions, Byte) | Parse the specified input buffer into a new Received instance. |
| Parse(Byte, Int32, Int32) | Parse the specified input buffer into a new Received instance. |
| Parse(ParserOptions, Byte, Int32, Int32) | Parse the specified input buffer into a new Received instance. |
| ToString |
Serializes the Received value to a string.
(Overrides ObjectToString) |
| ToString(FormatOptions) | Serializes the Received value to a string. |
| TryParse(Byte, Received) | Try to parse the given input buffer into a new Received instance. |
| TryParse(ParserOptions, Byte, Received) | Try to parse the given input buffer into a new Received instance. |
| TryParse(Byte, Int32, Int32, Received) | Try to parse the given input buffer into a new Received instance. |
| TryParse(ParserOptions, Byte, Int32, Int32, Received) | Try to parse the given input buffer into a new Received instance. |