Package io.rong.imkit.conversation.messgelist.processor

## Interface IConversationBusinessProcessor

- All Implemented Interfaces:

      public interface IConversationBusinessProcessor

  会话业务处理器

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class | Description
    --- | --- | ---

  - ### Field Summary

    Fields
    Modifier and Type | Field | Description
    --- | --- | ---

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---

  - ### Enum Constant Summary

    Enum Constants
    Enum Constant | Description
    --- | ---

  - ### Method Summary

    Modifier and Type | Method | Description
    --- | --- | ---
    `abstract void` | `init(MessageViewModel messageViewModel, Bundle bundle)` | 第一次初始化，绑定事件等
    `abstract boolean` | `onReceived(MessageViewModel messageViewModel, UiMessage message, int left, boolean hasPackage, boolean offline)` | 接收消息回调此接口
    `abstract boolean` | `onReceivedCmd(MessageViewModel messageViewModel, Message message)` | 接收到命令消息，(MessageTag 为 None 或 Status 的消息)
    `abstract void` | `onMessageItemClick(UiMessage uiMessage)` | 消息点击事件
    `abstract boolean` | `onMessageItemLongClick(UiMessage uiMessage)` | 消息长按事件
    `abstract void` | `onUserPortraitClick(Context context, ConversationType conversationType, UserInfo userInfo, String targetId)` | 用户头像点击事件
    `abstract boolean` | `onUserPortraitLongClick(Context context, ConversationType conversationType, UserInfo userInfo, String targetId)` | 用户头像长按事件
    `abstract boolean` | `onBackPressed(MessageViewModel viewModel)` |
    `abstract void` | `onDestroy(MessageViewModel viewModel)` |
    `abstract void` | `onExistUnreadMessage(MessageViewModel viewModel, Conversation conversation, int unreadMessageCount)` |
    `abstract void` | `onMessageReceiptRequest(MessageViewModel viewModel, ConversationType conversationType, String targetId, String messageUId)` |
    `abstract void` | `onLoadMessage(MessageViewModel viewModel, List<Message> messages)` |
    `abstract void` | `onConnectStatusChange(MessageViewModel viewModel, ConnectionStatus status)` |
    `abstract void` | `onResume(MessageViewModel viewModel)` |
    `abstract void` | `onLoadMore(MessageViewModel viewModel)` |
    `abstract void` | `onClearMessage(MessageViewModel viewModel)` |
    `abstract void` | `onRefresh(MessageViewModel viewModel)` |
    `abstract void` | `newMessageBarClick(MessageViewModel viewModel)` |
    `abstract void` | `unreadBarClick(MessageViewModel viewModel)` |
    `abstract void` | `newMentionMessageBarClick(MessageViewModel viewModel)` |
    `abstract boolean` | `isNormalState(MessageViewModel viewModel)` |
    `abstract boolean` | `isHistoryState(MessageViewModel viewModel)` |
    `abstract void` | `onScrollToBottom(MessageViewModel viewModel)` |

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

  - ### Method Detail

    - #### init

           abstract void init(MessageViewModel messageViewModel, Bundle bundle)

      第一次初始化，绑定事件等

      Parameters:
        `messageViewModel` - 消息处理类
        `bundle` - 上一个页面传递过来的 bundle

    - #### onReceived

           abstract boolean onReceived(MessageViewModel messageViewModel, UiMessage message, int left, boolean hasPackage, boolean offline)

      接收消息回调此接口

      Returns:

        是否拦截

    - #### onReceivedCmd

           abstract boolean onReceivedCmd(MessageViewModel messageViewModel, Message message)

      接收到命令消息，(MessageTag 为 None 或 Status 的消息)

      Parameters:
        `message` - 拦截的命令消息
      Returns:

        true，ui 不展示，false 在 ui 展示

    - #### onMessageItemClick

           abstract void onMessageItemClick(UiMessage uiMessage)

      消息点击事件

    - #### onMessageItemLongClick

           abstract boolean onMessageItemLongClick(UiMessage uiMessage)

      消息长按事件

      Returns:

        是否拦截

    - #### onUserPortraitClick

           abstract void onUserPortraitClick(Context context, ConversationType conversationType, UserInfo userInfo, String targetId)

      用户头像点击事件

    - #### onUserPortraitLongClick

           abstract boolean onUserPortraitLongClick(Context context, ConversationType conversationType, UserInfo userInfo, String targetId)

      用户头像长按事件

    - #### onBackPressed

           abstract boolean onBackPressed(MessageViewModel viewModel)

    - #### onDestroy

           abstract void onDestroy(MessageViewModel viewModel)

    - #### onExistUnreadMessage

           abstract void onExistUnreadMessage(MessageViewModel viewModel, Conversation conversation, int unreadMessageCount)

    - #### onMessageReceiptRequest

           abstract void onMessageReceiptRequest(MessageViewModel viewModel, ConversationType conversationType, String targetId, String messageUId)

    - #### onLoadMessage

           abstract void onLoadMessage(MessageViewModel viewModel, List<Message> messages)

    - #### onConnectStatusChange

           abstract void onConnectStatusChange(MessageViewModel viewModel, ConnectionStatus status)

    - #### onResume

           abstract void onResume(MessageViewModel viewModel)

    - #### onLoadMore

           abstract void onLoadMore(MessageViewModel viewModel)

    - #### onClearMessage

           abstract void onClearMessage(MessageViewModel viewModel)

    - #### onRefresh

           abstract void onRefresh(MessageViewModel viewModel)

    - #### newMessageBarClick

           abstract void newMessageBarClick(MessageViewModel viewModel)

    - #### unreadBarClick

           abstract void unreadBarClick(MessageViewModel viewModel)

    - #### newMentionMessageBarClick

           abstract void newMentionMessageBarClick(MessageViewModel viewModel)

    - #### isNormalState

           abstract boolean isNormalState(MessageViewModel viewModel)

    - #### isHistoryState

           abstract boolean isHistoryState(MessageViewModel viewModel)

    - #### onScrollToBottom

           abstract void onScrollToBottom(MessageViewModel viewModel)