Private Chat

You can lock a chat by tapping the name of a one-to-one or group and selecting the lock option

Set Private Chat#

Private chat can be enabled/disabled by calling this method.

    ChatManager.setPrivateChat(jid: String, isPrivate: Bool)
    ArgumentTypeDescription
    JIDStringJid of user to enable/disable private chat
    ISPRIVATEBooltrue to enable private chat false to disable private chat

    Private Chat Status#

    Get Private Chat Status by calling this method

      let isPrivateChat:Bool = ChatManager.isPrivateChat(jid: String)
      ArgumentTypeDescription
      JIDStringJid of user to get private chat status

      Get Private Chats List#

      An private chat won't be listed in recent chat list. To get the list of private chats call the below method.

        ChatManager.getPrivateChatList { (isSuccess, flyError, resultDict) in
        if (isSuccess) {
        let privateChatArray = data.getData() as? [RecentChat]
        } else {
        }
        }
        ArgumentTypeDescription
        CALLBACKFlyCompletionHandlerFlyCompletionHandler used as completion Handler

        Get Unread Message and Chat count for Private Chat#

        To get unread count of message and chat of private chats

          let (messageCount, chatCount) = ChatManager.getUnreadPrivateChatMessageAndChatCount()