setChatArchived static method
Future<void>
setChatArchived({
- required String jid,
- required bool isArchived,
- required dynamic flyCallBack(
- FlyResponse response
Provides functionality to set the archived status of a chat.
This method allows the user to update the archived status of a chat identified
by the unique identifier jid
. If isArchived
is true
, the chat will be
archived; if false
, it will be unarchived.
The flyCallBack
parameter is a function that will be called upon completion of the operation.
It receives a FlyResponse object as a parameter, which contains information about the success or failure of the operation.
Example usage:
Mirrorfly.setChatArchived(jid: 'unique_chat_jid', isArchived: true,flyCallBack:(response){
bool isChatArchived = response.isSuccess;
});
print('Chat archived status: $isChatArchived');
Implementation
static Future<void> setChatArchived(
{required String jid,
required bool isArchived,
required Function(FlyResponse response) flyCallBack}) {
return FlyChatFlutterPlatform.instance
.setChatArchived(jid, isArchived, flyCallBack);
}