@zegocloud/zimkit-react
Version:
ZEGO ZIMKit SDK for Web React
24 lines (23 loc) • 1.67 kB
TypeScript
import ZIMKitChatVM from './ZIMKitChatVM';
import ZIMKitConversationVM from '../../ZIMKitConversation/VM/ZIMKitConversationVM';
import { ZIMUserInfo, ZIMKitConversationType } from "../../ZIMAdapter/index.entity";
import { ZIMKitTextMessageModel, ZIMKitImgMessageModel, ZIMKitAudioMessageModel, ZIMKitVideoMessageModel, ZIMKitFileMessageModel } from "../Model";
export default class ZIMKitChatListVM {
private static instance;
chatList: Map<string, ZIMKitChatVM>;
currentConversation: ZIMKitConversationVM;
currentChat: ZIMKitChatVM;
mode: number;
constructor();
static getInstance(): ZIMKitChatListVM;
initListenerHandle(): void;
registerLoginUserUpdatedCallback(callback: (userInfo: ZIMUserInfo) => void): void;
registerCurrentChatChangedCallback(callback: (currentChat: ZIMKitChatVM) => void): void;
removeCurrentChatChangedCallback(callback: (currentChat: ZIMKitChatVM) => void): void;
registerCurrentChatUpdatedCallback(callback: (currentChat: ZIMKitChatVM) => void): void;
removeCurrentChatUpdatedCallback(callback: (currentChat: ZIMKitChatVM) => void): void;
registerModeChangedCallback(callback: (mode: number, message: ZIMKitTextMessageModel | ZIMKitImgMessageModel | ZIMKitAudioMessageModel | ZIMKitVideoMessageModel | ZIMKitFileMessageModel) => void): void;
removeModeChangedCallback(callback: (mode: number, message: ZIMKitTextMessageModel | ZIMKitImgMessageModel | ZIMKitAudioMessageModel | ZIMKitVideoMessageModel | ZIMKitFileMessageModel) => void): void;
initWithConversationID(conversationID: string, type: ZIMKitConversationType, conversationName?: string): void;
unInit(): void;
}