createChatroomAudioMessage static method

Future<NIMResult<NIMChatroomMessage>> createChatroomAudioMessage(
  1. {required String roomId,
  2. required String filePath,
  3. required int duration,
  4. NIMNosScene nosScene = NIMNosScenes.defaultIm}
)

创建音频消息

Implementation

static Future<NIMResult<NIMChatroomMessage>> createChatroomAudioMessage({
  required String roomId,
  required String filePath,
  required int duration,
  NIMNosScene nosScene = NIMNosScenes.defaultIm,
}) async {
  return NimCore.instance.chatroomService._createMessage({
    'roomId': roomId,
    'filePath': filePath,
    'duration': duration,
    'nosScene': nosScene,
    'messageType': 'audio',
  });
}