public class RongMentionManager extends java.lang.Object implements IExtensionEventWatcher
Modifier and Type | Class and Description |
---|---|
static interface |
RongMentionManager.IGroupMemberCallback |
static interface |
RongMentionManager.IGroupMembersProvider |
Modifier and Type | Method and Description |
---|---|
void |
createInstance(Conversation.ConversationType conversationType,
java.lang.String targetId,
android.widget.EditText editText) |
void |
destroyInstance(Conversation.ConversationType conversationType,
java.lang.String targetId) |
RongMentionManager.IGroupMembersProvider |
getGroupMembersProvider() |
static RongMentionManager |
getInstance() |
java.lang.String |
getMentionBlockInfo() |
void |
mentionMember(Conversation.ConversationType conversationType,
java.lang.String targetId,
java.lang.String userId) |
void |
mentionMember(UserInfo userInfo) |
void |
onDeleteClick(Conversation.ConversationType type,
java.lang.String targetId,
android.widget.EditText editText,
int cursorPos) |
void |
onDestroy(Conversation.ConversationType type,
java.lang.String targetId) |
void |
onSendToggleClick(Message message)
Extension 模块点击发送按钮时的预处理,其它模块可以通过此回调设置附加信息到 Extension
|
void |
onTextChanged(android.content.Context context,
Conversation.ConversationType conversationType,
java.lang.String targetId,
int cursorPos,
int offset,
java.lang.String text)
当输入框文本变化时,回调此方法。
|
void |
setAddMentionedMemberListener(IAddMentionedMemberListener listener) |
void |
setGroupMembersProvider(RongMentionManager.IGroupMembersProvider groupMembersProvider)
设置群组成员提供者。
'@' 功能和VoIP功能在选人界面,需要知道群组内成员信息,开发者需要设置该提供者。 开发者需要在回调中获取到群成员信息
并通过
RongMentionManager.IGroupMemberCallback 中的方法设置到 sdk 中
|
void |
setMentionedInputListener(IMentionedInputListener listener) |
public static RongMentionManager getInstance()
public void createInstance(Conversation.ConversationType conversationType, java.lang.String targetId, android.widget.EditText editText)
public void destroyInstance(Conversation.ConversationType conversationType, java.lang.String targetId)
public void mentionMember(Conversation.ConversationType conversationType, java.lang.String targetId, java.lang.String userId)
public void mentionMember(UserInfo userInfo)
public java.lang.String getMentionBlockInfo()
public void onTextChanged(android.content.Context context, Conversation.ConversationType conversationType, java.lang.String targetId, int cursorPos, int offset, java.lang.String text)
onTextChanged
in interface IExtensionEventWatcher
conversationType
- 会话类型targetId
- 目标 idcursorPos
- 输入文本时,光标位置初始位置offset
- 文本的变化量:增加时为正数,减少是为负数text
- 文本内容public void onSendToggleClick(Message message)
IExtensionEventWatcher
onSendToggleClick
in interface IExtensionEventWatcher
message
- extension 模块点击发送按钮时构建的初始消息。其它模块可以更改该消息里的配置。public void onDeleteClick(Conversation.ConversationType type, java.lang.String targetId, android.widget.EditText editText, int cursorPos)
onDeleteClick
in interface IExtensionEventWatcher
public void onDestroy(Conversation.ConversationType type, java.lang.String targetId)
onDestroy
in interface IExtensionEventWatcher
public RongMentionManager.IGroupMembersProvider getGroupMembersProvider()
public void setMentionedInputListener(IMentionedInputListener listener)
public void setAddMentionedMemberListener(IAddMentionedMemberListener listener)
public void setGroupMembersProvider(RongMentionManager.IGroupMembersProvider groupMembersProvider)
RongMentionManager.IGroupMemberCallback
中的方法设置到 sdk 中
groupMembersProvider
- 群组成员提供者。