saveTextMessageDraft static method
根据消息类型,targetId 保存某一会话的文字消息草稿。用于暂存用户输入但未发送的消息
Implementation
static Future<bool?> saveTextMessageDraft(int? conversationType, String? targetId, String? textContent) async {
if (conversationType == null || targetId == null || textContent == null) {
developer.log("saveTextMessageDraft fail: conversationType or targetId or content is null", name: "RongIMClient");
return null;
}
Map paramMap = {"conversationType": conversationType, "targetId": targetId, "content": textContent};
bool? result = await _channel.invokeMethod(RCMethodKey.SaveTextMessageDraft, paramMap);
return result;
}