package cn.rongcloud.im.wrapper.rn;

import androidx.annotation.NonNull;
import com.facebook.react.bridge.Promise;
import com.facebook.react.bridge.ReactApplicationContext;
import com.facebook.react.bridge.ReactContextBaseJavaModule;
import com.facebook.react.bridge.ReactMethod;
import com.facebook.react.bridge.ReadableArray;
import com.facebook.react.bridge.ReadableMap;

public class ReactNativeImModule extends ReactContextBaseJavaModule {
  private ReactNativeImModuleImpl impl;

  public ReactNativeImModule(ReactApplicationContext reactContext) {
    super(reactContext);
    this.impl = new ReactNativeImModuleImpl(reactContext);
  }

  @Override
  @NonNull
  public String getName() {
    return ReactNativeImModuleImpl.NAME;
  }

  @ReactMethod
  public void create(String appKey, ReadableMap options) {
    impl.create(appKey, options);
  }

  @ReactMethod
  public void destroy(Promise promise) {
    impl.destroy(promise);
  }

  @ReactMethod
  public void setDeviceToken(String deviceToken, Promise promise) {
    impl.setDeviceToken(deviceToken, promise);
  }

  @ReactMethod
  public void registerNativeCustomMessage(
      String messageIdentifier, double persistentFlag, Promise promise) {
    impl.registerNativeCustomMessage(messageIdentifier, persistentFlag, promise);
  }

  @ReactMethod
  public void registerNativeCustomMediaMessage(
      String messageIdentifier, double persistentFlag, Promise promise) {
    impl.registerNativeCustomMediaMessage(messageIdentifier, persistentFlag, promise);
  }

  @ReactMethod
  public void connect(String token, double timeout, String eventId, Promise promise) {
    impl.connect(token, timeout, eventId, promise);
  }

  @ReactMethod
  public void disconnect(boolean receivePush, Promise promise) {
    impl.disconnect(receivePush, promise);
  }

  @ReactMethod
  public void createTextMessage(
      double type, String targetId, String channelId, String text, Promise promise) {
    impl.createTextMessage(type, targetId, channelId, text, promise);
  }

  @ReactMethod
  public void createImageMessage(
      double type, String targetId, String channelId, String path, Promise promise) {
    impl.createImageMessage(type, targetId, channelId, path, promise);
  }

  @ReactMethod
  public void createFileMessage(
      double type, String targetId, String channelId, String path, Promise promise) {
    impl.createFileMessage(type, targetId, channelId, path, promise);
  }

  @ReactMethod
  public void createSightMessage(
      double type,
      String targetId,
      String channelId,
      String path,
      double duration,
      Promise promise) {
    impl.createSightMessage(type, targetId, channelId, path, duration, promise);
  }

  @ReactMethod
  public void createVoiceMessage(
      double type,
      String targetId,
      String channelId,
      String path,
      double duration,
      Promise promise) {
    impl.createVoiceMessage(type, targetId, channelId, path, duration, promise);
  }

  @ReactMethod
  public void createReferenceMessage(
      double type,
      String targetId,
      String channelId,
      ReadableMap referenceMessage,
      String text,
      Promise promise) {
    impl.createReferenceMessage(type, targetId, channelId, referenceMessage, text, promise);
  }

  @ReactMethod
  public void createGIFMessage(
      double type, String targetId, String channelId, String path, Promise promise) {
    impl.createGIFMessage(type, targetId, channelId, path, promise);
  }

  @ReactMethod
  public void createCustomMessage(
      double type,
      String targetId,
      String channelId,
      double policy,
      String messageIdentifier,
      ReadableMap fields,
      Promise promise) {
    impl.createCustomMessage(type, targetId, channelId, policy, messageIdentifier, fields, promise);
  }

  @ReactMethod
  public void createLocationMessage(
      double type,
      String targetId,
      String channelId,
      double longitude,
      double latitude,
      String poiName,
      String thumbnailPath,
      Promise promise) {
    impl.createLocationMessage(
        type, targetId, channelId, longitude, latitude, poiName, thumbnailPath, promise);
  }

  @ReactMethod
  public void createNativeCustomMessage(
      double type,
      String targetId,
      String channelId,
      String messageIdentifier,
      ReadableMap fields,
      Promise promise) {
    impl.createNativeCustomMessage(type, targetId, channelId, messageIdentifier, fields, promise);
  }

  @ReactMethod
  public void createNativeCustomMediaMessage(
      double type,
      String targetId,
      String channelId,
      String messageIdentifier,
      String path,
      ReadableMap fields,
      Promise promise) {
    impl.createNativeCustomMediaMessage(
        type, targetId, channelId, messageIdentifier, path, fields, promise);
  }

  @ReactMethod
  public void sendMessage(ReadableMap message, String eventId, Promise promise) {
    impl.sendMessage(message, eventId, promise);
  }

  @ReactMethod
  public void sendMediaMessage(ReadableMap message, String eventId, Promise promise) {
    impl.sendMediaMessage(message, eventId, promise);
  }

  @ReactMethod
  public void cancelSendingMediaMessage(ReadableMap message, String eventId, Promise promise) {
    impl.cancelSendingMediaMessage(message, eventId, promise);
  }

  @ReactMethod
  public void downloadMediaMessage(ReadableMap message, String eventId, Promise promise) {
    impl.downloadMediaMessage(message, eventId, promise);
  }

  @ReactMethod
  public void cancelDownloadingMediaMessage(ReadableMap message, String eventId, Promise promise) {
    impl.cancelDownloadingMediaMessage(message, eventId, promise);
  }

  @ReactMethod
  public void getConversation(
      double type, String targetId, String channelId, String eventId, Promise promise) {
    impl.getConversation(type, targetId, channelId, eventId, promise);
  }

  @ReactMethod
  public void getConversations(
      ReadableArray conversationTypes,
      String channelId,
      double startTime,
      double count,
      String eventId,
      Promise promise) {
    impl.getConversations(conversationTypes, channelId, startTime, count, eventId, promise);
  }

  @ReactMethod
  public void getUnreadConversations(
      ReadableArray conversationTypes, String eventId, Promise promise) {
    impl.getUnreadConversations(conversationTypes, eventId, promise);
  }

  @ReactMethod
  public void removeConversation(
      double type, String targetId, String channelId, String eventId, Promise promise) {
    impl.removeConversation(type, targetId, channelId, eventId, promise);
  }

  @ReactMethod
  public void removeConversations(
      ReadableArray conversationTypes, String channelId, String eventId, Promise promise) {
    impl.removeConversations(conversationTypes, channelId, eventId, promise);
  }

  @ReactMethod
  public void getUnreadCount(
      double type, String targetId, String channelId, String eventId, Promise promise) {
    impl.getUnreadCount(type, targetId, channelId, eventId, promise);
  }

  @ReactMethod
  public void getTotalUnreadCount(String channelId, String eventId, Promise promise) {
    impl.getTotalUnreadCount(channelId, eventId, promise);
  }

  @ReactMethod
  public void getUnreadMentionedCount(
      double type, String targetId, String channelId, String eventId, Promise promise) {
    impl.getUnreadMentionedCount(type, targetId, channelId, eventId, promise);
  }

  @ReactMethod
  public void getUltraGroupAllUnreadCount(String eventId, Promise promise) {
    impl.getUltraGroupAllUnreadCount(eventId, promise);
  }

  @ReactMethod
  public void getUltraGroupAllUnreadMentionedCount(String eventId, Promise promise) {
    impl.getUltraGroupAllUnreadMentionedCount(eventId, promise);
  }

  @ReactMethod
  public void getUltraGroupUnreadCount(String targetId, String eventId, Promise promise) {
    impl.getUltraGroupUnreadCount(targetId, eventId, promise);
  }

  @ReactMethod
  public void getUltraGroupUnreadMentionedCount(String targetId, String eventId, Promise promise) {
    impl.getUltraGroupUnreadMentionedCount(targetId, eventId, promise);
  }

  @ReactMethod
  public void getUnreadCountByConversationTypes(
      ReadableArray conversationTypes,
      String channelId,
      boolean contain,
      String eventId,
      Promise promise) {
    impl.getUnreadCountByConversationTypes(conversationTypes, channelId, contain, eventId, promise);
  }

  @ReactMethod
  public void clearUnreadCount(
      double type,
      String targetId,
      String channelId,
      double timestamp,
      String eventId,
      Promise promise) {
    impl.clearUnreadCount(type, targetId, channelId, timestamp, eventId, promise);
  }

  @ReactMethod
  public void saveDraftMessage(
      double type,
      String targetId,
      String channelId,
      String draft,
      String eventId,
      Promise promise) {
    impl.saveDraftMessage(type, targetId, channelId, draft, eventId, promise);
  }

  @ReactMethod
  public void getDraftMessage(
      double type, String targetId, String channelId, String eventId, Promise promise) {
    impl.getDraftMessage(type, targetId, channelId, eventId, promise);
  }

  @ReactMethod
  public void clearDraftMessage(
      double type, String targetId, String channelId, String eventId, Promise promise) {
    impl.clearDraftMessage(type, targetId, channelId, eventId, promise);
  }

  @ReactMethod
  public void getBlockedConversations(
      ReadableArray conversationTypes, String channelId, String eventId, Promise promise) {
    impl.getBlockedConversations(conversationTypes, channelId, eventId, promise);
  }

  @ReactMethod
  public void changeConversationTopStatus(
      double type,
      String targetId,
      String channelId,
      boolean top,
      String eventId,
      Promise promise) {
    impl.changeConversationTopStatus(type, targetId, channelId, top, eventId, promise);
  }

  @ReactMethod
  public void getConversationTopStatus(
      double type, String targetId, String channelId, String eventId, Promise promise) {
    impl.getConversationTopStatus(type, targetId, channelId, eventId, promise);
  }

  @ReactMethod
  public void syncConversationReadStatus(
      double type,
      String targetId,
      String channelId,
      double timestamp,
      String eventId,
      Promise promise) {
    impl.syncConversationReadStatus(type, targetId, channelId, timestamp, eventId, promise);
  }

  @ReactMethod
  public void sendTypingStatus(
      double type, String targetId, String channelId, String currentType, Promise promise) {
    impl.sendTypingStatus(type, targetId, channelId, currentType, promise);
  }

  @ReactMethod
  public void getMessages(
      double type,
      String targetId,
      String channelId,
      double sentTime,
      double order,
      double policy,
      double count,
      String eventId,
      Promise promise) {
    impl.getMessages(type, targetId, channelId, sentTime, order, policy, count, eventId, promise);
  }

  @ReactMethod
  public void getMessageById(double messageId, String eventId, Promise promise) {
    impl.getMessageById(messageId, eventId, promise);
  }

  @ReactMethod
  public void getMessageByUId(String messageUId, String eventId, Promise promise) {
    impl.getMessageByUId(messageUId, eventId, promise);
  }

  @ReactMethod
  public void getFirstUnreadMessage(
      double type, String targetId, String channelId, String eventId, Promise promise) {
    impl.getFirstUnreadMessage(type, targetId, channelId, eventId, promise);
  }

  @ReactMethod
  public void getUnreadMentionedMessages(
      double type, String targetId, String channelId, String eventId, Promise promise) {
    impl.getUnreadMentionedMessages(type, targetId, channelId, eventId, promise);
  }

  @ReactMethod
  public void insertMessage(ReadableMap message, String eventId, Promise promise) {
    impl.insertMessage(message, eventId, promise);
  }

  @ReactMethod
  public void insertMessages(ReadableArray messages, String eventId, Promise promise) {
    impl.insertMessages(messages, eventId, promise);
  }

  @ReactMethod
  public void clearMessages(
      double type,
      String targetId,
      String channelId,
      double timestamp,
      double policy,
      String eventId,
      Promise promise) {
    impl.clearMessages(type, targetId, channelId, timestamp, policy, eventId, promise);
  }

  @ReactMethod
  public void deleteLocalMessages(ReadableArray messages, String eventId, Promise promise) {
    impl.deleteLocalMessages(messages, eventId, promise);
  }

  @ReactMethod
  public void deleteMessages(
      double type,
      String targetId,
      String channelId,
      ReadableArray messages,
      String eventId,
      Promise promise) {
    impl.deleteMessages(type, targetId, channelId, messages, eventId, promise);
  }

  @ReactMethod
  public void recallMessage(ReadableMap message, String eventId, Promise promise) {
    impl.recallMessage(message, eventId, promise);
  }

  @ReactMethod
  public void sendPrivateReadReceiptMessage(
      String targetId, String channelId, double timestamp, String eventId, Promise promise) {
    impl.sendPrivateReadReceiptMessage(targetId, channelId, timestamp, eventId, promise);
  }

  @ReactMethod
  public void sendGroupReadReceiptRequest(ReadableMap message, String eventId, Promise promise) {
    impl.sendGroupReadReceiptRequest(message, eventId, promise);
  }

  @ReactMethod
  public void sendGroupReadReceiptResponse(
      String targetId, String channelId, ReadableArray messages, String eventId, Promise promise) {
    impl.sendGroupReadReceiptResponse(targetId, channelId, messages, eventId, promise);
  }

  @ReactMethod
  public void updateMessageExpansion(
      String messageUId, ReadableMap expansion, String eventId, Promise promise) {
    impl.updateMessageExpansion(messageUId, expansion, eventId, promise);
  }

  @ReactMethod
  public void removeMessageExpansionForKeys(
      String messageUId, ReadableArray keys, String eventId, Promise promise) {
    impl.removeMessageExpansionForKeys(messageUId, keys, eventId, promise);
  }

  @ReactMethod
  public void changeMessageSentStatus(
      double messageId, double sentStatus, String eventId, Promise promise) {
    impl.changeMessageSentStatus(messageId, sentStatus, eventId, promise);
  }

  @ReactMethod
  public void changeMessageReceiveStatus(
      double messageId, double receivedStatus, String eventId, Promise promise) {
    impl.changeMessageReceiveStatus(messageId, receivedStatus, eventId, promise);
  }

  @ReactMethod
  public void joinChatRoom(
      String targetId, double messageCount, boolean autoCreate, String eventId, Promise promise) {
    impl.joinChatRoom(targetId, messageCount, autoCreate, eventId, promise);
  }

  @ReactMethod
  public void leaveChatRoom(String targetId, String eventId, Promise promise) {
    impl.leaveChatRoom(targetId, eventId, promise);
  }

  @ReactMethod
  public void getChatRoomMessages(
      String targetId,
      double timestamp,
      double order,
      double count,
      String eventId,
      Promise promise) {
    impl.getChatRoomMessages(targetId, timestamp, order, count, eventId, promise);
  }

  @ReactMethod
  public void addChatRoomEntry(
      String targetId,
      String key,
      String value,
      boolean deleteWhenLeft,
      boolean overwrite,
      String eventId,
      Promise promise) {
    impl.addChatRoomEntry(targetId, key, value, deleteWhenLeft, overwrite, eventId, promise);
  }

  @ReactMethod
  public void addChatRoomEntries(
      String targetId,
      ReadableMap entries,
      boolean deleteWhenLeft,
      boolean overwrite,
      String eventId,
      Promise promise) {
    impl.addChatRoomEntries(targetId, entries, deleteWhenLeft, overwrite, eventId, promise);
  }

  @ReactMethod
  public void getChatRoomEntry(String targetId, String key, String eventId, Promise promise) {
    impl.getChatRoomEntry(targetId, key, eventId, promise);
  }

  @ReactMethod
  public void getChatRoomAllEntries(String targetId, String eventId, Promise promise) {
    impl.getChatRoomAllEntries(targetId, eventId, promise);
  }

  @ReactMethod
  public void removeChatRoomEntry(
      String targetId, String key, boolean force, String eventId, Promise promise) {
    impl.removeChatRoomEntry(targetId, key, force, eventId, promise);
  }

  @ReactMethod
  public void removeChatRoomEntries(
      String targetId, ReadableArray keys, boolean force, String eventId, Promise promise) {
    impl.removeChatRoomEntries(targetId, keys, force, eventId, promise);
  }

  @ReactMethod
  public void addToBlacklist(String userId, String eventId, Promise promise) {
    impl.addToBlacklist(userId, eventId, promise);
  }

  @ReactMethod
  public void removeFromBlacklist(String userId, String eventId, Promise promise) {
    impl.removeFromBlacklist(userId, eventId, promise);
  }

  @ReactMethod
  public void getBlacklistStatus(String userId, String eventId, Promise promise) {
    impl.getBlacklistStatus(userId, eventId, promise);
  }

  @ReactMethod
  public void getBlacklist(String eventId, Promise promise) {
    impl.getBlacklist(eventId, promise);
  }

  @ReactMethod
  public void searchMessages(
      double type,
      String targetId,
      String channelId,
      String keyword,
      double startTime,
      double count,
      String eventId,
      Promise promise) {
    impl.searchMessages(type, targetId, channelId, keyword, startTime, count, eventId, promise);
  }

  @ReactMethod
  public void searchMessagesByTimeRange(
      double type,
      String targetId,
      String channelId,
      String keyword,
      double startTime,
      double endTime,
      double offset,
      double count,
      String eventId,
      Promise promise) {
    impl.searchMessagesByTimeRange(
        type, targetId, channelId, keyword, startTime, endTime, offset, count, eventId, promise);
  }

  @ReactMethod
  public void searchMessagesByUserId(
      String userId,
      double type,
      String targetId,
      String channelId,
      double startTime,
      double count,
      String eventId,
      Promise promise) {
    impl.searchMessagesByUserId(
        userId, type, targetId, channelId, startTime, count, eventId, promise);
  }

  @ReactMethod
  public void searchConversations(
      ReadableArray conversationTypes,
      String channelId,
      ReadableArray messageTypes,
      String keyword,
      String eventId,
      Promise promise) {
    impl.searchConversations(conversationTypes, channelId, messageTypes, keyword, eventId, promise);
  }

  @ReactMethod
  public void changeNotificationQuietHours(
      String startTime, double spanMinutes, double level, String eventId, Promise promise) {
    impl.changeNotificationQuietHours(startTime, spanMinutes, level, eventId, promise);
  }

  @ReactMethod
  public void removeNotificationQuietHours(String eventId, Promise promise) {
    impl.removeNotificationQuietHours(eventId, promise);
  }

  @ReactMethod
  public void getNotificationQuietHours(String eventId, Promise promise) {
    impl.getNotificationQuietHours(eventId, promise);
  }

  @ReactMethod
  public void changeConversationNotificationLevel(
      double type,
      String targetId,
      String channelId,
      double level,
      String eventId,
      Promise promise) {
    impl.changeConversationNotificationLevel(type, targetId, channelId, level, eventId, promise);
  }

  @ReactMethod
  public void getConversationNotificationLevel(
      double type, String targetId, String channelId, String eventId, Promise promise) {
    impl.getConversationNotificationLevel(type, targetId, channelId, eventId, promise);
  }

  @ReactMethod
  public void changeConversationTypeNotificationLevel(
      double type, double level, String eventId, Promise promise) {
    impl.changeConversationTypeNotificationLevel(type, level, eventId, promise);
  }

  @ReactMethod
  public void getConversationTypeNotificationLevel(double type, String eventId, Promise promise) {
    impl.getConversationTypeNotificationLevel(type, eventId, promise);
  }

  @ReactMethod
  public void changeUltraGroupDefaultNotificationLevel(
      String targetId, double level, String eventId, Promise promise) {
    impl.changeUltraGroupDefaultNotificationLevel(targetId, level, eventId, promise);
  }

  @ReactMethod
  public void getUltraGroupDefaultNotificationLevel(
      String targetId, String eventId, Promise promise) {
    impl.getUltraGroupDefaultNotificationLevel(targetId, eventId, promise);
  }

  @ReactMethod
  public void changeUltraGroupChannelDefaultNotificationLevel(
      String targetId, String channelId, double level, String eventId, Promise promise) {
    impl.changeUltraGroupChannelDefaultNotificationLevel(
        targetId, channelId, level, eventId, promise);
  }

  @ReactMethod
  public void getUltraGroupChannelDefaultNotificationLevel(
      String targetId, String channelId, String eventId, Promise promise) {
    impl.getUltraGroupChannelDefaultNotificationLevel(targetId, channelId, eventId, promise);
  }

  @ReactMethod
  public void changePushContentShowStatus(boolean showContent, String eventId, Promise promise) {
    impl.changePushContentShowStatus(showContent, eventId, promise);
  }

  @ReactMethod
  public void changePushLanguage(String language, String eventId, Promise promise) {
    impl.changePushLanguage(language, eventId, promise);
  }

  @ReactMethod
  public void changePushReceiveStatus(boolean receive, String eventId, Promise promise) {
    impl.changePushReceiveStatus(receive, eventId, promise);
  }

  @ReactMethod
  public void sendGroupMessageToDesignatedUsers(
      ReadableMap message, ReadableArray userIds, String eventId, Promise promise) {
    impl.sendGroupMessageToDesignatedUsers(message, userIds, eventId, promise);
  }

  @ReactMethod
  public void getMessageCount(
      double type, String targetId, String channelId, String eventId, Promise promise) {
    impl.getMessageCount(type, targetId, channelId, eventId, promise);
  }

  @ReactMethod
  public void getTopConversations(
      ReadableArray conversationTypes, String channelId, String eventId, Promise promise) {
    impl.getTopConversations(conversationTypes, channelId, eventId, promise);
  }

  @ReactMethod
  public void syncUltraGroupReadStatus(
      String targetId, String channelId, double timestamp, String eventId, Promise promise) {
    impl.syncUltraGroupReadStatus(targetId, channelId, timestamp, eventId, promise);
  }

  @ReactMethod
  public void getConversationsForAllChannel(
      double type, String targetId, String eventId, Promise promise) {
    impl.getConversationsForAllChannel(type, targetId, eventId, promise);
  }

  @ReactMethod
  public void modifyUltraGroupMessage(
      String messageUId, ReadableMap message, String eventId, Promise promise) {
    impl.modifyUltraGroupMessage(messageUId, message, eventId, promise);
  }

  @ReactMethod
  public void recallUltraGroupMessage(
      ReadableMap message, boolean deleteRemote, String eventId, Promise promise) {
    impl.recallUltraGroupMessage(message, deleteRemote, eventId, promise);
  }

  @ReactMethod
  public void clearUltraGroupMessages(
      String targetId,
      String channelId,
      double timestamp,
      double policy,
      String eventId,
      Promise promise) {
    impl.clearUltraGroupMessages(targetId, channelId, timestamp, policy, eventId, promise);
  }

  @ReactMethod
  public void sendUltraGroupTypingStatus(
      String targetId, String channelId, double typingStatus, String eventId, Promise promise) {
    impl.sendUltraGroupTypingStatus(targetId, channelId, typingStatus, eventId, promise);
  }

  @ReactMethod
  public void clearUltraGroupMessagesForAllChannel(
      String targetId, double timestamp, String eventId, Promise promise) {
    impl.clearUltraGroupMessagesForAllChannel(targetId, timestamp, eventId, promise);
  }

  @ReactMethod
  public void getBatchRemoteUltraGroupMessages(
      ReadableArray messages, String eventId, Promise promise) {
    impl.getBatchRemoteUltraGroupMessages(messages, eventId, promise);
  }

  @ReactMethod
  public void updateUltraGroupMessageExpansion(
      String messageUId, ReadableMap expansion, String eventId, Promise promise) {
    impl.updateUltraGroupMessageExpansion(messageUId, expansion, eventId, promise);
  }

  @ReactMethod
  public void removeUltraGroupMessageExpansionForKeys(
      String messageUId, ReadableArray keys, String eventId, Promise promise) {
    impl.removeUltraGroupMessageExpansionForKeys(messageUId, keys, eventId, promise);
  }

  @ReactMethod
  public void changeLogLevel(double level, Promise promise) {
    impl.changeLogLevel(level, promise);
  }

  @ReactMethod
  public void getDeltaTime(Promise promise) {
    impl.getDeltaTime(promise);
  }

  @ReactMethod
  public void createTag(String tagId, String tagName, String eventId, Promise promise) {
    impl.createTag(tagId, tagName, eventId, promise);
  }

  @ReactMethod
  public void removeTag(String tagId, String eventId, Promise promise) {
    impl.removeTag(tagId, eventId, promise);
  }

  @ReactMethod
  public void updateTagNameById(String tagId, String newName, String eventId, Promise promise) {
    impl.updateTagNameById(tagId, newName, eventId, promise);
  }

  @ReactMethod
  public void getTags(String eventId, Promise promise) {
    impl.getTags(eventId, promise);
  }

  @ReactMethod
  public void addConversationToTag(
      String tagId, double type, String targetId, String eventId, Promise promise) {
    impl.addConversationToTag(tagId, type, targetId, eventId, promise);
  }

  @ReactMethod
  public void removeConversationFromTag(
      String tagId, double type, String targetId, String eventId, Promise promise) {
    impl.removeConversationFromTag(tagId, type, targetId, eventId, promise);
  }

  @ReactMethod
  public void removeTagsFromConversation(
      double type, String targetId, ReadableArray tagIds, String eventId, Promise promise) {
    impl.removeTagsFromConversation(type, targetId, tagIds, eventId, promise);
  }

  @ReactMethod
  public void getTagsFromConversation(
      double type, String targetId, String eventId, Promise promise) {
    impl.getTagsFromConversation(type, targetId, eventId, promise);
  }

  @ReactMethod
  public void getConversationsFromTagByPage(
      String tagId, double timestamp, double count, String eventId, Promise promise) {
    impl.getConversationsFromTagByPage(tagId, timestamp, count, eventId, promise);
  }

  @ReactMethod
  public void getUnreadCountByTag(String tagId, boolean contain, String eventId, Promise promise) {
    impl.getUnreadCountByTag(tagId, contain, eventId, promise);
  }

  @ReactMethod
  public void changeConversationTopStatusInTag(
      String tagId, double type, String targetId, boolean top, String eventId, Promise promise) {
    impl.changeConversationTopStatusInTag(tagId, type, targetId, top, eventId, promise);
  }

  @ReactMethod
  public void getConversationTopStatusInTag(
      String tagId, double type, String targetId, String eventId, Promise promise) {
    impl.getConversationTopStatusInTag(tagId, type, targetId, eventId, promise);
  }

  @ReactMethod
  public void clearMessagesUnreadStatusByTag(String tagId, String eventId, Promise promise) {
    impl.clearMessagesUnreadStatusByTag(tagId, eventId, promise);
  }

  @ReactMethod
  public void clearConversationsByTag(
      String tagId, boolean deleteMessage, String eventId, Promise promise) {
    impl.clearConversationsByTag(tagId, deleteMessage, eventId, promise);
  }
}
