Pop 3ClientSet Language Method
Set the language used by the POP3 server for error messages.
Definition
Namespace: MailKit.Net.Pop3
Assembly: MailKit (in MailKit.dll) Version: 5.0.0
Assembly: MailKit (in MailKit.dll) Version: 5.0.0
C#
public void SetLanguage(
string lang,
CancellationToken cancellationToken = default
)Parameters
- lang String
- The language code.
- cancellationToken CancellationToken (Optional)
- The cancellation token.
Implements
IPop3ClientSetLanguage(String, CancellationToken)Remarks
If the POP3 server supports the LANG extension, it is possible to
set the language used by the POP3 server for error messages.
Exceptions
| ArgumentNullException | lang is . |
| ArgumentException | lang is empty. |
| ObjectDisposedException | The Pop3Client has been disposed. |
| ServiceNotConnectedException | The Pop3Client is not connected. |
| OperationCanceledException | The operation was canceled via the cancellation token. |
| NotSupportedException | The POP3 server does not support the LANG extension. |
| IOException | An I/O error occurred. |
| Pop3CommandException | The POP3 command failed. |
| Pop3ProtocolException | A POP3 protocol error occurred. |