Class SmtpSessionState
Represents the state of an SMTP session associated with a client.
Inherited Members
Namespace: Swan.Net.Smtp
Syntax
public class SmtpSessionState
Constructors
SmtpSessionState()
Initializes a new instance of the SmtpSessionState class.
Declaration
public SmtpSessionState()
Properties
AuthMode
Gets or sets the authentication mode.
Declaration
public string AuthMode { get; set; }
Property Value
Type | Description |
---|---|
String |
ClientHostname
Gets or sets the client hostname.
Declaration
public string ClientHostname { get; set; }
Property Value
Type | Description |
---|---|
String |
DataBuffer
Gets the contents of the data buffer.
Declaration
public List<byte> DataBuffer { get; protected set; }
Property Value
Type | Description |
---|---|
List<Byte> |
ExtendedData
Gets or sets the extended data supporting any additional field for storage by a responder implementation.
Declaration
public object ExtendedData { get; set; }
Property Value
Type | Description |
---|---|
Object |
HasInitiated
Gets or sets a value indicating whether this instance has initiated.
Declaration
public bool HasInitiated { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
HasProvidedUsername
Gets a value indicating whether this instance has provided username.
Declaration
public bool HasProvidedUsername { get; }
Property Value
Type | Description |
---|---|
Boolean |
IsAuthenticated
Gets or sets a value indicating whether this instance is authenticated.
Declaration
public bool IsAuthenticated { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
IsChannelSecure
Gets or sets a value indicating whether this instance is channel secure.
Declaration
public bool IsChannelSecure { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
IsInAuthMode
Gets or sets a value indicating whether this instance is in authentication mode.
Declaration
public bool IsInAuthMode { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
IsInDataMode
Gets or sets a value indicating whether the session is currently receiving DATA.
Declaration
public bool IsInDataMode { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
Password
Gets or sets the password.
Declaration
public string Password { get; set; }
Property Value
Type | Description |
---|---|
String |
Recipients
Gets the recipients.
Declaration
public List<string> Recipients { get; }
Property Value
Type | Description |
---|---|
List<String> |
SenderAddress
Gets or sets the sender address.
Declaration
public string SenderAddress { get; set; }
Property Value
Type | Description |
---|---|
String |
SupportsExtensions
Gets or sets a value indicating whether the current session supports extensions.
Declaration
public bool SupportsExtensions { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
Username
Gets or sets the username.
Declaration
public string Username { get; set; }
Property Value
Type | Description |
---|---|
String |
Methods
Clone()
Creates a new object that is a copy of the current instance.
Declaration
public virtual SmtpSessionState Clone()
Returns
Type | Description |
---|---|
SmtpSessionState | A clone. |
Reset(Boolean)
Resets the state table entirely.
Declaration
public void Reset(bool clearExtensionData)
Parameters
Type | Name | Description |
---|---|---|
Boolean | clearExtensionData | if set to |
ResetAuthentication()
Resets the authentication state.
Declaration
public void ResetAuthentication()
ResetEmail()
Resets the data mode to false, clears the recipients, the sender address and the data buffer.
Declaration
public void ResetEmail()