AitManager class

@消息管理类

Constructors

AitManager(String teamId, {bool isP2P = false})

Properties

aitContactsModel → dynamic
no setter
aitMemberList ValueNotifier<List<AitBean>?>
暴露成员列表通知器,供桌面端弹框监听
no setter
aiUserList List<AitBean>
暴露 AI 用户列表,供桌面端弹框使用
no setter
hashCode int
The hash code for this object.
no setterinherited
isP2P bool
是否为 P2P 单聊场景,P2P 场景下只展示 AI 数字人
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
teamId String
final

Methods

addAitWithText(String account, String name, int startIndex) → void
通过@文本添加@用户
addTextWithoutAit(String changeText, int endIndex, int length) → void
新增Text输入,但输入的不是@ 会进行移位或者删除,如果在@XXX 中插入文本 @XXX 会被删除 changeText 输入后的文案 endIndex 输入的结束位置 length 输入的长度
aitEnd(String text) bool
@用户 是否在文本最后,如果在文本最后,需要在文本后面添加空格
cleanAit() → void
清理@用户,在发送之后调用
deleteAitWithText(String deletedText, int endIndex, int length) → AitMsg?
根据插入后的Text 文案, segment 移位或者删除。 返回被删除的AitMsg信息 deletedText 删除后的字符串 endIndex 删除的结束位置 length 删除的长度
dispose() → void
forkAit(AitContactsModel aitContactsModel) → void
复制@用户信息,用户撤回消息使用
getPushList() List<String>
后去需要推送的用户列表
haveAitMember() bool
是否有@成员
haveBeAit(String account) bool
是否已经在@列表中
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
refreshMemberList() → void
刷新成员列表(从当前 NIMChatCache 实时获取),供桌面端弹框显示前调用 防止切换会话时初始化读到旧缓存
resetAitCursor(int baseIndex) int
光标移动到@后自动到后面
selectMember(BuildContext context) Future
选择@的成员
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited