Performs an IQ set/get request asynchronously and optionally invokes a callback method when the IQ response comes in.

Namespace: S22.Xmpp.Core
Assembly: S22.Xmpp (in S22.Xmpp.dll) Version: 1.0.0.0 (1.0.0.0)

Syntax

C#
public string IqRequestAsync(
	Iq request,
	Action<string, Iq> callback = null
)

Parameters

request
Type: S22.Xmpp.Core..::..Iq
The IQ request to send.
callback (Optional)
Type: System..::..Action<(Of <(<'String, Iq>)>)>
A callback method which is invoked once the IQ response from the server comes in.

Return Value

The ID value of the pending IQ stanza request.

Exceptions

ExceptionCondition
System..::..ArgumentNullExceptionThe request parameter is null.
System..::..ArgumentExceptionThe type parameter is not IqType.Set or IqType.Get.
System..::..ObjectDisposedExceptionThe XmppCore object has been disposed.
System..::..InvalidOperationExceptionThe XmppCore instance is not connected to a remote host.
System.IO..::..IOExceptionThere was a failure while writing to the network.

See Also