C# Class agsXMPP.IqGrabber

Inheritance: PacketGrabber
Mostrar archivo Open project: SiteView/ECC8.13 Class Usage Examples

Public Methods

Method Description
IqGrabber ( XmppClientConnection conn ) : System

OnIq ( object sender, agsXMPP.protocol.client.IQ iq ) : void

An IQ Element is received. Now check if its one we are looking for and raise the event in this case.

Remove ( string id ) : void

Pending request can be removed. This is useful when a ressource for the callback is destroyed and we are not interested anymore at the result.

SendIq ( agsXMPP.protocol.client.IQ iq ) : agsXMPP.protocol.client.IQ

Sends an Iq synchronous and return the response or null on timeout. Timeout time used is SynchronousTimeout

SendIq ( agsXMPP.protocol.client.IQ iq, int timeout ) : agsXMPP.protocol.client.IQ

Sends an Iq synchronous and return the response or null on timeout

SendIq ( agsXMPP.protocol.client.IQ iq, IqCB cb, object cbArg ) : void

Send an IQ Request and store the object with callback in the Hashtable

Private Methods

Method Description
SynchronousIqResult ( object sender, agsXMPP.protocol.client.IQ iq, object data ) : void

Callback for synchronous iq grabbing

Method Details

IqGrabber() public method

public IqGrabber ( XmppClientConnection conn ) : System
conn XmppClientConnection
return System

OnIq() public method

An IQ Element is received. Now check if its one we are looking for and raise the event in this case.
public OnIq ( object sender, agsXMPP.protocol.client.IQ iq ) : void
sender object
iq agsXMPP.protocol.client.IQ
return void

Remove() public method

Pending request can be removed. This is useful when a ressource for the callback is destroyed and we are not interested anymore at the result.
public Remove ( string id ) : void
id string ID of the Iq we are not interested anymore
return void

SendIq() public method

Sends an Iq synchronous and return the response or null on timeout. Timeout time used is SynchronousTimeout
public SendIq ( agsXMPP.protocol.client.IQ iq ) : agsXMPP.protocol.client.IQ
iq agsXMPP.protocol.client.IQ The IQ to send
return agsXMPP.protocol.client.IQ

SendIq() public method

Sends an Iq synchronous and return the response or null on timeout
public SendIq ( agsXMPP.protocol.client.IQ iq, int timeout ) : agsXMPP.protocol.client.IQ
iq agsXMPP.protocol.client.IQ The IQ to send
timeout int
return agsXMPP.protocol.client.IQ

SendIq() public method

Send an IQ Request and store the object with callback in the Hashtable
public SendIq ( agsXMPP.protocol.client.IQ iq, IqCB cb, object cbArg ) : void
iq agsXMPP.protocol.client.IQ The iq to send
cb IqCB the callback function which gets raised for the response
cbArg object additional object for arguments
return void