Retrieve Messages
#
Get messages using idsTo get array of messages from database using their message ids, call the below method.
Argument | Type | Description |
---|---|---|
MESSAGE_MIDS | [String] | Ids of messages |
#
Get messages of a user/groupTo fetch all the conversation between you and a single chat user or group, call the below method.
Argument | Type | Description |
---|---|---|
JID | String | Jid of the chat user/group |
#
Get messages by pagination#
InitializationCreate a FetchMessageListParams
instance. Here, you can set the message filter to determine the message order and the starting point of the message list in the chat view.
Argument | Type | Description |
---|---|---|
CHAT_ID | String | Jid of the user/group |
MESSAGE_ID | String | Message id of the starting point optional |
MESSAGE_TIME | Double | Message time of the starting point optional |
EXCLUDE | Bool | If true starting point message will be excluded in message list default true |
ASCENDING_ORDER | Bool | If true message list will be returned ascendingOrder by message time default false |
LIMIT | Int | No of messages will be fetched for each request default 50 |
TOPIC_ID | String | Topic ID to be fetched` |
Secondly, create a FetchMessageListQuery
instance.
Argument | Type | Description |
---|---|---|
MESSAGE_LIST_PARAM | FetchMessageListParams | 'Insatance of 'FetchMessageListParams' |
#
Load Initial MessagesTo fetch initial conversations between you and a single chat user or group, call the below method.
Argument | Type | Description |
---|---|---|
CALLBACK | FlyCompletionHandler | FlyCompletionHandler implemented as closures |
#
Load Previous MessagesTo fetch previous conversations between you and a single chat user or group, call the below method.
Argument | Type | Description |
---|---|---|
CALLBACK | FlyCompletionHandler | FlyCompletionHandler implemented as closures |
#
Load Next MessagesTo fetch next conversations between you and a single chat user or group, call the below method.
Argument | Type | Description |
---|---|---|
CALLBACK | FlyCompletionHandler | FlyCompletionHandler implemented as closures |
#
Check Previous Set of Messages availabilityTo check previous set of conversations available or not, call the below method.
#
Check Next Set of Messages availabilityTo check next set of conversations available or not, call the below method.
#
Check Message Fetching InProgressTo check conversations fetching in progress or not, call the below method.
#
Get media messagesTo get the media messages of a conversation, call the below method.
Argument | Type | Description |
---|---|---|
JID | String | Jid of the chat user/group |
To get Video, Image, and Audio messages a conversation, call the below method. It is used in view all media to get array of messages group by month
Argument | Type | Description |
---|---|---|
jid | String | jid of the chat user/group |
#
Unread countif you want to get the unread count of chat messages, you can utilise the below method.