 | ImapSendCommandAsync(String, Boolean, CancellationToken) Method |
Sends command and waits for the server response.
Namespace: Limilabs.Client.IMAPAssembly: Mail (in Mail.dll) Version: 3.0.26106.1555
Syntaxpublic Task<ImapResponse> SendCommandAsync(
string command,
bool throwException,
CancellationToken cancel = default
)
Public Function SendCommandAsync (
command As String,
throwException As Boolean,
Optional cancel As CancellationToken = Nothing
) As Task(Of ImapResponse)
public:
Task<ImapResponse^>^ SendCommandAsync(
String^ command,
bool throwException,
CancellationToken cancel = CancellationToken()
)
member SendCommandAsync :
command : string *
throwException : bool *
?cancel : CancellationToken
(* Defaults:
let _cancel = defaultArg cancel new CancellationToken()
*)
-> Task<ImapResponse> Parameters
- command String
- Command e.g. "NOOP".
- throwException Boolean
- If true throws ImapResponseException on error response.
- cancel CancellationToken (Optional)
- A cancellation token that can be used to signal the asynchronous operation should be canceled.
Return Value
TaskImapResponseIMAP response object.
Remarks
Most commands have their own specialized methods in this class, you should probably use them instead.
See Also