sendTextMessage method
- {required String sessionId,
- required NIMSessionType sessionType,
- required String text,
- MessageAction? action}
发送文本消息
Implementation
Future<NIMResult<NIMMessage>> sendTextMessage({
required String sessionId,
required NIMSessionType sessionType,
required String text,
MessageAction? action,
}) async {
final message = NIMMessage.textEmptyMessage(
sessionId: sessionId, sessionType: sessionType, text: text);
return _createMessageAndSend(message, action);
}