Description
Handles incoming responses from other users to requests from the gateway to be added to their buddy lists. Also receives requests from buddies to have you remove them from your buddy list.
Syntax
onAddBuddyResponse(CFEvent) |
See also
onIncomingMessage, onAddBuddyRequest, onBuddyStatus, onIMServerMessage
Parameters
The method must take one parameter, a CFEvent structure with the following fields:
Field |
Description |
---|---|
gatewayType |
Gateway type, either XMPP or SAMETIME. |
gatewayID |
The ID of the gateway instance, as configured in ColdFusion Administrator. |
originatorID |
The IM ID of the message originator. |
cfcMethod |
This CFC method; by default, onAddBuddyResponse. |
data.MESSAGE |
One of the following:
|
data.SENDER |
The sender's ID; identical to the originatorID. |
data.RECIPIENT |
The recipient's ID, as specified in the gateway's configuration file. |
data.TIMESTAMP |
The date and time when the message was sent. |
Returns
The function does not return a value.
Example
The following example adds the buddy's status to the Application scope buddyStatus structure if the message sender accepted an add buddy request. It logs all responses.
<cffunction name="onAddBuddyResponse"> |