Click or drag to resize
MimeKit

ProtocolException Class

The exception that is thrown when there is a protocol error.
Inheritance Hierarchy

Namespace: MailKit
Assembly: MailKit (in MailKit.dll) Version: 4.3.0
Syntax
C#
[SerializableAttribute]
public abstract class ProtocolException : Exception

The ProtocolException type exposes the following members.

Constructors
 NameDescription
Protected methodProtocolException Initializes a new instance of the ProtocolException class.
Protected methodProtocolException(String) Initializes a new instance of the ProtocolException class.
Protected methodProtocolException(SerializationInfo, StreamingContext) Initializes a new instance of the ProtocolException class.
Protected methodProtocolException(String, Exception) Initializes a new instance of the ProtocolException class.
Top
Properties
 NameDescription
Public propertyData
(Inherited from Exception)
Public propertyHelpLink
(Inherited from Exception)
Public propertyHResult
(Inherited from Exception)
Public propertyInnerException
(Inherited from Exception)
Public propertyMessage
(Inherited from Exception)
Public propertySource
(Inherited from Exception)
Public propertyStackTrace
(Inherited from Exception)
Public propertyTargetSite
(Inherited from Exception)
Top
Methods
 NameDescription
Public methodEquals
(Inherited from Object)
Protected methodFinalize
(Inherited from Object)
Public methodGetBaseException
(Inherited from Exception)
Public methodGetHashCode
(Inherited from Object)
Public methodGetObjectData
(Inherited from Exception)
Public methodGetType
(Inherited from Exception)
Protected methodMemberwiseClone
(Inherited from Object)
Public methodToString
(Inherited from Exception)
Top
Events
 NameDescription
Protected eventSerializeObjectState
(Inherited from Exception)
Top
Remarks

A ProtocolException can be thrown by any of the various client methods in MailKit.

Since many protocol exceptions are fatal, it is important to check whether or not the client is still connected using the IsConnected property when this exception is thrown.

See Also