sendUserBinaryMessage method

FutureOr<long> sendUserBinaryMessage(
  1. String userId,
  2. ArrayBuffer buffer,
  3. MessageConfig config
)

@detail api @brief Sends a point-to-point binary message to the specified user in the room. @param userId Message Receives user ID @param buffer Binary message content sent. Message does not exceed 46KB. @param config See MessageConfig{@link #MessageConfig} @note - Before sending in-room binary messages, you must call joinRTSRoom{@link #RTSRoom#joinRTSRoom} to join the room. - After the call, you will receive an onUserMessageSendResult{@link #IRTSRoomEventHandler#onUserMessageSendResult} callback to notify that the message was sent successfully or failed; - If the message was sent successfully, the user specified by the userId will receive an onUserBinaryMessageReceived{@link #IRTSRoomEventHandler#onUserBinaryMessageReceived} callback.

Implementation

FutureOr<long> sendUserBinaryMessage(
    String userId, ArrayBuffer buffer, MessageConfig config) async {
  return await nativeCall(
      'sendUserBinaryMessage', [userId, buffer, config.$value]);
}