setConversationToTop static method
设置会话置顶
conversationType
会话类型,参见枚举 RCConversationType
targetId
会话 id
isTop
是否设置置顶
finished
回调结果,code 为 0 代表正常
Implementation
static Future<void> setConversationToTop(int conversationType, String targetId, bool isTop, Function(bool? status, int? code)? finished) async {
Map map = {"conversationType": conversationType, "targetId": targetId, "isTop": isTop};
Map? conversationMap = await _channel.invokeMethod(RCMethodKey.SetConversationToTop, map);
if (finished != null) {
finished(conversationMap!["status"], conversationMap["code"]);
}
}