Callback Delegates
#
FlyCompletionHandlerFlyCompletionHandler is used as a base callback block for most of the IO operations.
#
Observe Chat ConnectionTo observe the chat connection status you must adopt a protocol 'ConnectionEventDelegate' through ChatManager
- Swift
- Objective-C
#
Observe Profile EventsTo observe profile related events you can must adopt a protocol 'ProfileEventsDelegate' through ContactsManager
Example:
- Swift
- Objective-C
#
Contacts Profiles Fetched.If the client application has mobile number as the primary identifier of the user and enabled contact sync they can fetch their contacts data and its completion is triggered in the following callbacks.
- Swift
- Objective-C
#
User blocked youIf a user blocked you then the following method will be triggered in the ProfileEventsDelegate.
- Swift
- Objective-C
#
User unblocked youIf a user unblocked you then the following method will be triggered in the ProfileEventsDelegate.
- Swift
- Objective-C
#
User Updated his profileIf a user updated his profile then the following method will be triggered in the ProfileEventsDelegate.
- Swift
- Objective-C
#
My Profile update statusOnce you initiated the update for your profile its status will be triggered by the following method in the ProfileEventsDelegate.
- Swift
- Objective-C
#
User came onlineIf a user came online then the following method will be triggered in the ProfileEventsDelegate.
- Swift
- Objective-C
#
User went offineIf a user went offline then the following method will be triggered in the ProfileEventsDelegate.
- Swift
- Objective-C
#
Users blocked me list callbackWhen called to get the users who blocked me then the following method will be triggered in the ProfileEventsDelegate.
- Swift
- Objective-C
#
Users i blocked list callbackWhen called to get the users who i blocked then the following method will be triggered in the ProfileEventsDelegate.
- Swift
- Objective-C
#
User profile fetchedWhen called to get the profile detatil of a user from the server then the following method will be triggered in the ProfileEventsDelegate.
- Swift
- Objective-C
#
Block a userWhen called to block a user then the following method will be triggered in the ProfileEventsDelegate.
- Swift
- Objective-C
#
UnBlock a userWhen called to unblock a user then the following method will be triggered in the ProfileEventsDelegate.
- Swift
- Objective-C
#
User profile deletedWhen other user deleted their profile then the following method will be triggered in the ProfileEventsDelegate.
- Swift
- Objective-C
#
Observe Group EventsTo observe group related events you must adopt a protocol GroupEventsDelegate
Example:
- Swift
- Objective-C
#
Group Profile FetchedWhen the request for fetching a group profile is completed successfully this delegate will be triggered.
- Swift
- Objective-C
#
Group notification message receivedWhen events like new member added or member removed a notification message will be generated locally and inserted in the local database. After insertion this delegate will be triggered.
- Swift
- Objective-C
#
New group createdWhen a new group was created like when someone added you to a group this delegate will be triggered.
- Swift
- Objective-C
#
Group profile updatedWhen a group profile is updated this delegate will be triggered.
- Swift
- Objective-C
#
New member added to groupWhen a new member is added to the group this delegate will be triggered.
- Swift
- Objective-C
#
Member removed from groupWhen a member is removed from the group this delegate will be triggered.
- Swift
- Objective-C
#
Fetching group membersWhen a group is created, members of that group will be fetched once sucessfully fetched this delegate will be triggered.
- Swift
- Objective-C
#
Group member became an adminWhen a group member became an admin this delegate will be triggered.
- Swift
- Objective-C
#
Admin access revokedWhen a group member's admin access is revoked this delegate will be triggered.
- Swift
- Objective-C
#
Member left from the groupWhen a member left the group this delegate will be triggered.
- Swift
- Objective-C
#
Group deleted locallyWhen the current user delete a group locally this delegate will be triggered.
- Swift
- Objective-C
#
Observing the message eventsYou need to conform the MessageEventsDelegate protocol to observe all the message related events, so that you can update the UI immediately based on the message events.Once you have sent the message via sdk, you will get the callbacks for message status events.You can attach your own listener by using the below method. This is common for both single chat and groups.
tip
There can be only one message listener at a time, if you set multiple times using the below method it will always replace the old listener.
info
For group, message status will be updated only if all the participants sent the delivery/seen status.
#
Observe User Busy StatusTo observe the status of user is busy or not, And to get the busy message must adopt a protocol 'UserBusyStatusDelegate' through ChatManager
#
Handling Banned User/Group#
Current UserTo observe current user blocking/unblocking, confirm to AdminBlockCurrentUserDelegate
#
Contacts and GroupTo observe contact and group blocking/unblocking, confirm to AdminBlockDelegate
#
Observing the Archive Chats eventsTo observe chat Archive/Unarchive, confirm to ArchiveEventsDelegate
- Swift
- Objective-C
#
Observing the all Incoming Message Notifications on ForegroundTo observe all Incoming Message Notifications on Foreground, confirm to LocalNotificationDelegate in AppDelegate
- Swift
- Objective-C
#
Observing the Backup Chats eventsTo observe backup chat progress, confirm to BackupEventDelegate
- Swift
- Objective-C
#
Observing the Restore Chats eventsTo observe restore chat progress, confirm to RestoreEventDelegate
- Swift
- Objective-C