human: 如何处理七牛云的即时通讯BMXChatServiceListener

gpt: [即时通讯](https://developer.qiniu.com/IM) > API 文档 > [ANDROID
API](https://developer.qiniu.com/IM/api/8191/android-im-class-indexes) >
BMXChatServiceListener

#  BMXChatServiceListener

最近更新时间: 2022-07-22 22:59:05

class im.floo.floolib.BMXChatServiceListener

聊天监听者

Index

字段

  * swigCMemOwn

方法

  * getCPtr
  * finalize
  * delete
  * swigDirectorDisconnect
  * swigReleaseOwnership
  * swigTakeOwnership
  * onStatusChanged
  * onAttachmentUploadProgressChanged
  * onRecallStatusChanged
  * onReceive
  * onReceiveCommandMessages
  * onReceiveSystemMessages
  * onReceiveReadAcks
  * onReceiveDeliverAcks
  * onReceiveRecallMessages
  * onReceiveReadCancels
  * onReceiveReadAllMessages
  * onReceiveDeleteMessages
  * onReceivePlayAcks
  * onAttachmentStatusChanged
  * onAttachmentDownloadByUrlStatusChanged
  * onRetrieveHistoryMessages
  * onLoadAllConversation
  * onConversationCreate
  * onConversationDelete
  * onTotalUnreadCountChanged
  * registerChatService

字段

swigCMemOwn

  * protected transient boolean swigCMemOwn
  * 

方法

getCPtr

  * protected static long getCPtr(BMXChatServiceListener obj);
  * Returns long

finalize

  * protected void finalize();
  * Returns void

delete

  * public synchronized void delete();
  * Returns void

swigDirectorDisconnect

  * protected void swigDirectorDisconnect();
  * Returns void

swigReleaseOwnership

  * public void swigReleaseOwnership();
  * Returns void

swigTakeOwnership

  * public void swigTakeOwnership();
  * Returns void

onStatusChanged

  * public void onStatusChanged(BMXMessage msg, BMXErrorCode error);
  * 消息发送状态发生变化

Parameters

    * msg: [BMXMessage](https://developer.qiniu.com/IM/api/8239/bmxmessage)

发生状态变化的消息

    * error: BMXErrorCode 

状态错误码

Returns void

onAttachmentUploadProgressChanged

  * public void onAttachmentUploadProgressChanged(BMXMessage msg, int percent);
  * 附件上传进度发送变化

Parameters

    * msg: [BMXMessage](https://developer.qiniu.com/IM/api/8239/bmxmessage)

上传附件的消息

    * percent: int 

附件上传的进度

Returns void

onRecallStatusChanged

  * public void onRecallStatusChanged(BMXMessage msg, BMXErrorCode error);
  * 消息撤回状态发送变化

Parameters

    * msg: [BMXMessage](https://developer.qiniu.com/IM/api/8239/bmxmessage)

撤回状态发生变化的消息

    * error: BMXErrorCode 

状态错误码

Returns void

onReceive

  * public void onReceive(BMXMessageList list);
  * 收到消息

Parameters

    * list: BMXMessageList 

接收到的消息列表

Returns void

onReceiveCommandMessages

  * public void onReceiveCommandMessages(BMXMessageList list);
  * 收到命令消息

Parameters

    * list: BMXMessageList 

接收到的消息列表

Returns void

onReceiveSystemMessages

  * public void onReceiveSystemMessages(BMXMessageList list);
  * 收到系统通知消息

Parameters

    * list: BMXMessageList 

接收到的系统消息列表

Returns void

onReceiveReadAcks

  * public void onReceiveReadAcks(BMXMessageList list);
  * 收到消息已读回执

Parameters

    * list: BMXMessageList 

接收到的已读回执消息列表

Returns void

onReceiveDeliverAcks

  * public void onReceiveDeliverAcks(BMXMessageList list);
  * 收到消息已送达回执

Parameters

    * list: BMXMessageList 

接收到的已送达回执消息列表

Returns void

onReceiveRecallMessages

  * public void onReceiveRecallMessages(BMXMessageList list);
  * 收到撤回消息

Parameters

    * list: BMXMessageList 

接收到的撤回消息列表

Returns void

onReceiveReadCancels

  * public void onReceiveReadCancels(BMXMessageList list);
  * 收到消息已读取消（多设备其他设备同步消息已读状态变为未读）

Parameters

    * list: BMXMessageList 

接收到的消息已读取消消息列表

Returns void

onReceiveReadAllMessages

  * public void onReceiveReadAllMessages(BMXMessageList list);
  * 收到消息全部已读（多设备同步某消息之前消息全部设置为已读）

Parameters

    * list: BMXMessageList 

接收到的消息全部已读消息列表

Returns void

onReceiveDeleteMessages

  * public void onReceiveDeleteMessages(BMXMessageList list);
  * 收到删除消息 （多设备同步删除消息）

Parameters

    * list: BMXMessageList 

接收到的删除消息列表

Returns void

onReceivePlayAcks

  * public void onReceivePlayAcks(BMXMessageList list);
  * 收到消息已播放回执

Parameters

    * list: BMXMessageList 

接收到的已读回执消息列表

Returns void

onAttachmentStatusChanged

  * public void onAttachmentStatusChanged(BMXMessage msg, BMXErrorCode error, int percent);
  * 附件下载状态发生变化

Parameters

    * msg: [BMXMessage](https://developer.qiniu.com/IM/api/8239/bmxmessage)

发生下载状态变化的消息

    * error: BMXErrorCode 

状态错误码

    * percent: int 

附件下载的进度

Returns void

onAttachmentDownloadByUrlStatusChanged

  * public void onAttachmentDownloadByUrlStatusChanged(long msgId, BMXErrorCode error, int percent);
  * 附件下载状态发生变化

Parameters

    * msgId: long 

发生下载状态变化的消息ID

    * error: BMXErrorCode 

状态错误码

    * percent: int 

附件下载的进度

Returns void

onRetrieveHistoryMessages

  * public void onRetrieveHistoryMessages(BMXConversation conversation);
  * 拉取历史消息

Parameters

    * conversation: [BMXConversation](https://developer.qiniu.com/IM/api/8207/bmx-conversation)

发生了拉取指历史消息的会话

Returns void

onLoadAllConversation

  * public void onLoadAllConversation();
  * 已经加载完未读会话列表

Returns void

onConversationCreate

  * public void onConversationCreate(BMXConversation conversation, BMXMessage msg);
  * 本地创建新会话

Parameters

    * conversation: [BMXConversation](https://developer.qiniu.com/IM/api/8207/bmx-conversation)

新创建的本地会话

    * msg: [BMXMessage](https://developer.qiniu.com/IM/api/8239/bmxmessage)

会话的最新消息，存在返回不存在返回为空

Returns void

onConversationDelete

  * public void onConversationDelete(long conversationId, BMXErrorCode error);
  * 删除会话

Parameters

    * conversationId: long 

删除的本地会话id

    * error: BMXErrorCode 

状态错误码

Returns void

onTotalUnreadCountChanged

  * public void onTotalUnreadCountChanged(int unreadCount);
  * 更新总未读数

Parameters

    * unreadCount: int 

本地全部会话未读总数

Returns void

registerChatService

  * public void registerChatService(BMXChatService service);
  * Returns void

以上内容是否对您有帮助？