UNPKG

wildfire-im-sdk

Version:
292 lines (291 loc) 12.5 kB
export default class MessageConfig { static getMessageContentClazz(type: any): typeof TextMessageContent | typeof ImageMessageContent | typeof TipNotificationMessageContent | typeof UnknownMessageContent | typeof UnsupportMessageContent | typeof ChangeGroupNameNotification | typeof KickoffGroupMemberNotification | typeof AddGroupMemberNotification | typeof ChangeGroupPortraitNotification | typeof CreateGroupNotification | typeof ModifyGroupAliasNotification | typeof ModifyGroupExtraNotification | typeof ModifyGroupMemberExtraNotification | typeof TransferGroupOwnerNotification | typeof FileMessageContent | typeof VideoMessageContent | typeof StickerMessageContent | typeof SoundMessageContent | typeof TypingMessageContent | typeof DeleteMessageContent | typeof CallAnswerTMessageContent | typeof CallByeMessageContent | typeof CallSignalMessageContent | typeof MuteVideoMessageContent | typeof GroupJoinTypeNotificationContent | typeof GroupMuteNotificationContent | typeof GroupPrivateChatNotificationContent | typeof LocationMessageContent | typeof AllowGroupMemberNotification | typeof CardMessageContent | typeof LinkMessageContent | typeof CompositeMessageContent | typeof ModifyGroupSettingNotification | typeof StreamingTextGeneratingMessageContent | typeof ConferenceInviteMessageContent | typeof ConferenceChangeModeContent | typeof ConferenceKickoffMemberMessageContent | typeof MultiCallOngoingMessageContent | typeof JoinCallRequestMessageContent | typeof MarkUnreadMessageContent | typeof StartSecretChatNotification | typeof RichNotificationMessageContent | typeof ArticlesMessageContent | typeof ChannelMenuEventMessageContent | typeof EnterChannelChatMessageContent | typeof ConferenceCommandMessageContent | typeof MixFileTextMessageContent | typeof MixMultiMediaTextMessageContent; static getMessageContentFlag(type: any): number; static getMessageContentPersitFlag(type: any): number; static getMessageContentType(messageContent: any): number; static registerMessageContent(name: any, flag: any, type: any, clazz: any): void; static MessageContents: ({ name: string; flag: number; type: number; contentClazz: typeof UnknownMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof TextMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof SoundMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof ImageMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof LocationMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof FileMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof VideoMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof StickerMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof LinkMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof CardMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof CompositeMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof TipNotificationMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof TypingMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof AddGroupMemberNotification; } | { name: string; flag: number; type: number; contentClazz: typeof ChangeGroupNameNotification; } | { name: string; flag: number; type: number; contentClazz: typeof ChangeGroupPortraitNotification; } | { name: string; flag: number; type: number; contentClazz: typeof CreateGroupNotification; } | { name: string; flag: number; type: number; contentClazz: typeof KickoffGroupMemberNotification; } | { name: string; flag: number; type: number; contentClazz: typeof ModifyGroupAliasNotification; } | { name: string; flag: number; type: number; contentClazz: typeof ModifyGroupExtraNotification; } | { name: string; flag: number; type: number; contentClazz: typeof ModifyGroupMemberExtraNotification; } | { name: string; flag: number; type: number; contentClazz: typeof TransferGroupOwnerNotification; } | { name: string; flag: number; type: number; contentClazz: typeof GroupJoinTypeNotificationContent; } | { name: string; flag: number; type: number; contentClazz: typeof GroupMuteNotificationContent; } | { name: string; flag: number; type: number; contentClazz: typeof GroupPrivateChatNotificationContent; } | { name: string; flag: number; type: number; contentClazz: typeof AllowGroupMemberNotification; } | { name: string; flag: number; type: number; contentClazz: typeof ModifyGroupSettingNotification; } | { name: string; flag: number; type: number; contentClazz: typeof DeleteMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof StreamingTextGeneratingMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof CallAnswerTMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof CallByeMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof CallSignalMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof MuteVideoMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof ConferenceInviteMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof ConferenceChangeModeContent; } | { name: string; flag: number; type: number; contentClazz: typeof ConferenceKickoffMemberMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof MultiCallOngoingMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof JoinCallRequestMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof MarkUnreadMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof StartSecretChatNotification; } | { name: string; flag: number; type: number; contentClazz: typeof RichNotificationMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof ArticlesMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof ChannelMenuEventMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof EnterChannelChatMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof ConferenceCommandMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof MixFileTextMessageContent; } | { name: string; flag: number; type: number; contentClazz: typeof MixMultiMediaTextMessageContent; })[]; } import TextMessageContent from '../messages/textMessageContent'; import ImageMessageContent from '../messages/imageMessageContent'; import TipNotificationMessageContent from '../messages/notification/tipNotification'; import UnknownMessageContent from '../messages/unknownMessageContent'; import UnsupportMessageContent from '../messages/unsupportMessageConten'; import ChangeGroupNameNotification from '../messages/notification/changeGroupNameNotification'; import KickoffGroupMemberNotification from '../messages/notification/kickoffGroupMemberNotification'; import AddGroupMemberNotification from '../messages/notification/addGroupMemberNotification'; import ChangeGroupPortraitNotification from '../messages/notification/changeGroupPortraitNotification'; import CreateGroupNotification from '../messages/notification/createGroupNotification'; import ModifyGroupAliasNotification from '../messages/notification/modifyGroupAliasNotification'; import ModifyGroupExtraNotification from '../messages/notification/modifyGroupExtraNotification'; import ModifyGroupMemberExtraNotification from '../messages/notification/modifyGroupMemberExtraNotification'; import TransferGroupOwnerNotification from '../messages/notification/transferGroupOwnerNotification'; import FileMessageContent from '../messages/fileMessageContent'; import VideoMessageContent from '../messages/videoMessageContent'; import StickerMessageContent from '../messages/stickerMessageContent'; import SoundMessageContent from '../messages/soundMessageContent'; import TypingMessageContent from '../messages/typingMessageContent'; import DeleteMessageContent from '../messages/deleteMessageContent'; import CallAnswerTMessageContent from '../av/messages/callAnswerTMessageContent'; import CallByeMessageContent from '../av/messages/callByeMessageContent'; import CallSignalMessageContent from '../av/messages/callSignalMessageContent'; import MuteVideoMessageContent from "../av/messages/muteVideoMessageContent"; import GroupJoinTypeNotificationContent from "../messages/notification/groupJoinTypeNotificationContent"; import GroupMuteNotificationContent from "../messages/notification/groupMuteNotificationContent"; import GroupPrivateChatNotificationContent from "../messages/notification/groupPrivateChatNotificationContent"; import LocationMessageContent from "../messages/locationMessageContent"; import AllowGroupMemberNotification from '../messages/notification/allowGroupMemberNotification'; import CardMessageContent from '../messages/cardMessageContent'; import LinkMessageContent from "../messages/linkMessageContent"; import CompositeMessageContent from "../messages/compositeMessageContent"; import ModifyGroupSettingNotification from "../messages/notification/modifyGroupSettingNotification"; import StreamingTextGeneratingMessageContent from "../messages/streamingTextGeneratingMessageContent"; import ConferenceInviteMessageContent from "../av/messages/conferenceInviteMessageContent"; import ConferenceChangeModeContent from "../av/messages/conferenceChangeModeContent"; import ConferenceKickoffMemberMessageContent from "../av/messages/conferenceKickoffMemberMessageContent"; import MultiCallOngoingMessageContent from "../av/messages/multiCallOngoingMessageContent"; import JoinCallRequestMessageContent from "../av/messages/joinCallRequestMessageContent"; import MarkUnreadMessageContent from "../messages/markUnreadMessageContent"; import StartSecretChatNotification from "../messages/notification/startSecretChatNotification"; import RichNotificationMessageContent from "../messages/notification/richNotificationMessageContent"; import ArticlesMessageContent from "../messages/articlesMessageContent"; import ChannelMenuEventMessageContent from "../messages/channelMenuEventMessageContent"; import EnterChannelChatMessageContent from "../messages/enterChannelChatMessageContent"; import ConferenceCommandMessageContent from "../av/messages/conferenceCommandMessageContent"; import MixFileTextMessageContent from "../messages/mixFileTextMessageContent"; import MixMultiMediaTextMessageContent from "../messages/mixMultiMediaTextMessageContent";