// // MOTtmEntiry.h // MiMoLive // // Created by SuperC on 2023/11/21. // #import #import "MOGiftInfo.h" #import "MORoomDataModels.h" #import "MOUserBase.h" #import "MORoomDesire.h" NS_ASSUME_NONNULL_BEGIN @class MORtmToast, MORtmPkV2Status, MORtmPkV2StatusExpand, MORtmLivePKLinkInvite, MOLinePKViewModel; typedef enum : NSUInteger { MORtmEnter = 0, //进入房间 MORtmExit = 1, //退出房间 MORtmChat = 2, //发言 MORtmGift = 3, //礼物 MORtmLink = 4, //秀场直播 - 连麦 MORtmKick = 5, //秀场直播 - 踢人 MORtmChatSilence = 6, //秀场直播 - 禁言 MORtmChatManage = 7, //秀场直播 - 禁言 MORtmGiftEndNum = 8, //礼物数量提示 MORtmRoomTip = 9, //直播间提示 MORoomCleanRtmTip = 10, //直播间清屏提示 MOLikeComboTip = 11, //直播间点赞连击 MOWishListTip = 12, //心愿单更新数据 MOChangeRoomType = 13, //房间转换 MORoomTipTwo = 14, //通用提示类型 MORoomVoiceTranslate = 15, //直播间语音识别翻译 MORtmMicApply = 100, //麦位 - 申请上麦 MORtmMicActive = 101, //麦位 - 激活(上麦) MORtmMicLeave = 102, //麦位 - 下麦 MORtmMicAuditPass = 103, //麦位审核 - 通过 MORtmMicAuditRefuse = 104, //麦位审核 - 拒绝 MORtmMicInvite = 105, //麦位邀请 - 邀请 MORtmMicAccept = 106, //麦位申请 - 接受邀请 MORtmMicRefuse = 107, //麦位邀请 - 拒绝邀请 MOtRtmAudioApply = 200, //语音 - 申请发言 MORtmAudioOpen = 201, //语音 - 打开麦克风 MORtmAudioClose = 202, //语音 - 关闭麦克风 MORtmAudioSilence = 203, //语音 - 被禁言 MORtmAudioUndo = 204, //语言 - 禁言解除 MOPKStatus = 300, //PK相关信息 RoomClose = 500, //房间关闭 //带 Peer 的,均为点对点消息 PeerPK = 600, //PK 邀请 PeerPKMatch = 601, //PK 匹配成功 PeerPKQuit = 602, //PK 中途退出 PeerPKFinish = 603, //PK 正常结束退出 SystemOrder = 1000, //系统指令 SystemLiveUpdate = 1001, //房间信息更新指令 data 结构 SystemTipMsg = 10001, //系统提示 SystemTipVip = 10002, //会员提示 SystemTipChat = 10003, //聊天提示 SystemTipGift = 10004, //送礼提示 SystemTipGetRed = 10005, //领取红包提示 SystemTipNormalBlue = 10006, //通用蓝色提示 SystemTipRedRain = 10007, //红包雨提示 SystemTipHitDiamond = 10008, //礼物暴击 SystemTipBlindBox = 10009, //盲盒礼物装扮通知 }MORtmContentType; @interface MORtmFanBean : NSObject @property (nonatomic, assign) NSInteger level; @property (nonatomic, copy) NSString *name; @end @interface MORtmVipBean : NSObject @property (nonatomic, assign) NSInteger type; @property (nonatomic, copy) NSString *name; @end @interface MORtmFamilyBean : NSObject @property (nonatomic, assign) NSInteger level; @property (nonatomic, copy) NSString *name; @property (nonatomic, copy) NSString *nameplate; @end @interface MORtmHeaddress : NSObject @property (nonatomic, assign) NSInteger type;//头饰 - 头饰类型(0=无资源文件,1=动态webp,2=SVGA,3=VAP) @property (nonatomic, copy) NSString *res;//头饰 @end @interface MORtmDressing : NSObject @property (nonatomic, assign) NSInteger bubble;//气泡code @property (nonatomic, assign) NSInteger entryBar;// 入场座驾 Code @property (nonatomic, assign) NSInteger cardFrame;// 名片框 Code @property (nonatomic, assign) NSInteger enterFloating;// 进场飘屏 Code @property (nonatomic, assign) NSInteger rewardBanner;// 打赏横幅 Code @property (nonatomic, assign) NSInteger linkMicFrame;// 连麦边框 Code @property (nonatomic, assign) NSInteger liveBarrage;// 直播弹幕 Code @end @interface MORtmUser : NSObject @property (nonatomic, assign) NSInteger level; @property (nonatomic, copy) NSString *userId; @property (nonatomic, copy) NSString *username; @property (nonatomic, assign) NSInteger bubble; //气泡类型 @property (nonatomic, copy) NSString *headress;//头饰 @property (nonatomic, copy) NSString *avatar; @property (nonatomic, assign) NSInteger agoraId; @property (nonatomic, strong) MORtmVipBean *vip; @property (nonatomic, strong) MORtmFanBean *fans; @property (nonatomic, strong) MORtmFamilyBean *family; @property (nonatomic, assign) NSInteger wealthMedal;//财富勋章 @property (nonatomic, assign) NSInteger rides;//座驾 //RtmRoomUser @property (nonatomic, copy) NSString *id; @property (nonatomic, copy) NSString *nickname; @property (nonatomic, copy) NSString *userNo;//用户编号 @property (nonatomic, strong) NSArray *medalCodeList;//勋章Code @property (nonatomic, strong) MORtmHeaddress *headressObject;//头饰对象 - APP发送RTM用这个 @property (nonatomic, strong) MORtmHeaddress *headdress;//头饰对象 - 接受杨总的推送 @property (nonatomic, strong) MORtmDressing *dressing;//装饰类 @property (nonatomic, assign) NSInteger enterBarPlayType;//进场动画信息播放类型. 0=未知,1=后景播放,2=前景播放 @property (nonatomic, assign) NSInteger enterFloatingSkinType;//进场条皮肤类型. 0=未知,1=普通皮肤,2=神豪皮肤 @property (nonatomic, assign) BOOL enterFloatingAvatar;//进场条皮肤是否携带头像 @end //礼物返钻 @interface MORtmGiftRebate : NSObject @property (nonatomic, strong) MORtmUser *user; @property (nonatomic, strong) MORtmUser *anchor; @property (nonatomic, assign) NSInteger diamond;//返钻数量 @property (nonatomic, assign) NSInteger multiple;//返钻倍数 @property (nonatomic, assign) NSInteger giftCode; @property (nonatomic, assign) BOOL living; @property (nonatomic, copy) NSString *roomId; //Diamond Winner活动 //类型(1=免费,2=收费) @property (nonatomic, assign) NSInteger type; @property (nonatomic, copy) NSString *period;//期数 @property (nonatomic, copy) NSString *periodId;//期数 @end @interface MORedEnvelopeObject : NSObject @property (nonatomic, copy) NSString *redEnvelopeId; @property (nonatomic, copy) NSString *senderNickname; @property (nonatomic, assign) double serverTime; @property (nonatomic, assign) double startTime; @property (nonatomic, copy) NSString *sendUserId; @property (nonatomic, copy) NSString *roomId; @property (nonatomic, copy) NSString *senderAvatar; @end @interface MORtmRoomResolution : NSObject /** 分辨率 0->VideoEncoderConfiguration.VD_960x720. (720P) 1 -> VideoEncoderConfiguration.VD_960x540(540P) 2 -> VideoEncoderConfiguration.VD_640x480(480P) 3-> VideoEncoderConfiguration.VD_480x360(360P) */ @property (nonatomic, assign) NSInteger resolution; @end @interface MORtmFlexActivityPiggy : NSObject @property (nonatomic, assign) NSInteger diamond;//钻石数 @property (nonatomic, assign) int type;//类型(1=礼物,2=游戏) @end @interface MORtmUserDialogItem : NSObject @property (nonatomic, assign) int type;// 1.钻石,2=道具,3=礼物,4=只显示图片+名称 @property (nonatomic, copy) NSString *name;//名称 @property (nonatomic, copy) NSString *img;//图片 @property (nonatomic, assign) NSInteger amount;//1=钻石=数量,2=道具=天数,3=礼物=数量,4=不显示 @end @interface MORtmUserDialog : NSObject @property (nonatomic, copy) NSString *backgroundImg;//背景图 @property (nonatomic, assign) double giftTopNum;//礼物top位置百分百 (0.5就是顶部居中 0.6就是距离顶部0.6百分比) @property (nonatomic, copy) NSString *iconBackgroundImg;//图标背景图片 @property (nonatomic, copy) NSString *iconTextColor;//背景图 ("FFFFFF" // RGB (默认白色) #自己拼) @property (nonatomic, strong) NSArray *iconItems;//麦位信息变化, 返回变化的麦位信息 @end //礼物返钻 @interface MORtmLiveRoomViewer : NSObject /** 用户ID */ @property (nonatomic, copy) NSString *i; /** 用户头像 */ @property (nonatomic, copy) NSString *a; /** 用户装饰 */ @property (nonatomic, copy) NSString *b; /** 用户装扮是否动画 */ @property (nonatomic, assign) BOOL d; /** 用户头饰类型(0=无动效,1=动态WEBP,2=SGVA,3=VAP) */ @property (nonatomic, assign) NSInteger t; /** 用户头饰资源 */ @property (nonatomic, copy) NSString *r; @end @interface MORTMLinkMic : NSObject /** 变化的位置 */ @property (nonatomic, assign) NSInteger idx; /** 用户信息 */ @property (nonatomic, strong) MORtmUser *user; /** 麦位是否锁定 */ @property (nonatomic, assign) BOOL lock; /** 麦上用户 - 是否使用视频 */ @property (nonatomic, assign) BOOL video1; /** 麦上用户 - 主播是否允许使用视频 */ @property (nonatomic, assign) BOOL video2; /** 麦上用户 - 是否使用音频 */ @property (nonatomic, assign) BOOL audio1; /** 麦上用户 - 主播是否允许使用音频 */ @property (nonatomic, assign) BOOL audio2; /** 是否房管 */ @property (nonatomic, assign) BOOL admin; @property (nonatomic, assign) double goldenBean; /** 上麦时间 */ @property (nonatomic, assign) double uptime; @end @interface MORtmWishList : NSObject @property (nonatomic, assign) NSInteger giftCode; @property (nonatomic, assign) NSInteger num; @property (nonatomic, assign) NSInteger complete; @property (nonatomic, assign) BOOL done; @end //粉丝团 @interface MORtmFansClub : NSObject @property (nonatomic, copy) NSString *id;// 粉丝团ID @property (nonatomic, copy) NSString *name;// 粉丝团名称 @property (nonatomic, assign) NSInteger level;// 粉丝团等级 @end @interface MORtmOpenVipNotice : NSObject @property (nonatomic, assign) NSInteger vipLevel;//1-6 @property (nonatomic, assign) NSInteger buyType;//1:购买 2:续费 3:升级 @property (nonatomic, assign) NSInteger floatType;//1:房间.小 2:房间.中 3:全站中 4:全站大 @end @interface MORtmUserLevelUpgrade : NSObject @property (nonatomic, assign) NSInteger afterLevel;// 提升后的等级 @property (nonatomic, assign) NSInteger beforeLevel;// 提升前的等级 @property (nonatomic, assign) NSInteger noticeType;// 通知类型(1=仅自己、2=房间、3=全频道) @property (nonatomic, copy) NSString *rewardThumbnail;// 奖励缩略图 @property (nonatomic, assign) NSInteger effectsType;// 图片类型 @property (nonatomic, copy) NSString *effectsUrl;//特效资源 @end @interface MORtmFastGive : NSObject @property (nonatomic, copy) NSString *giftId;//礼物ID @property (nonatomic, assign) NSInteger diamond;//礼物钻石价格 @property (nonatomic, copy) NSString *giftName;//礼物名称 /** * 当 userNo 不为空的时候 说明本条消息 是推送给 userNo 对应用户的,其他人无需处理 * 为空的时候 所有人可以处理 */ @property (nonatomic, copy) NSString *userNo; @property (nonatomic, assign) NSInteger skinCode;//皮肤编码 @property (nonatomic, copy) NSString *giftImage; @end @interface MORtmFollowGive : NSObject @property (nonatomic, copy) NSString *giftId;//礼物ID @property (nonatomic, assign) NSInteger diamond;//礼物钻石价格 @property (nonatomic, copy) NSString *giftName;//礼物名称 @property (nonatomic, assign) NSInteger type;//1:礼物雨 2:里程碑 3:直播间活跃 @property (nonatomic, assign) NSInteger milestone;//type=2 里程碑的时候 本字段有效, 里程碑 数量 @property (nonatomic, assign) NSInteger skinCode;//皮肤编码 @property (nonatomic, copy) NSString *giftImage; @end @interface MORtmRoomDesireDone : NSObject @property (nonatomic, copy) NSString *giftId;//礼物ID @property (nonatomic, assign) NSInteger giftCode;//礼物上架Code @property (nonatomic, copy) NSString *giftImg;//礼物图片 @property (nonatomic, strong) MORtmUser *sender; @end @interface MORtmBlindboxGift : NSObject @property (nonatomic, copy) NSString *giftId;//礼物id @property (nonatomic, assign) int giftCode; @property (nonatomic, copy) NSString *giftImg; @property (nonatomic, assign) NSInteger amount; @end @interface MORtmBlindboxDrawResult : NSObject /** * 1:仅自己可见 * 2:直播间全员可见 * 3:全平台直播可见 */ @property (nonatomic, assign) int noticeType; @property (nonatomic, copy) NSString *userNo; @property (nonatomic, copy) NSString *nickname; @property (nonatomic, copy) NSString *avatar; @property (nonatomic, copy) NSString *roomId; @property (nonatomic, copy) NSString *userId; @property (nonatomic, copy) NSArray *propNotices;//装扮通知信息流列表-纯文字 @property (nonatomic, copy) NSArray *list; @property (nonatomic, assign) BOOL isShowGift;//是否显示礼物信息, NO代表显示装扮信息 @property (nonatomic, strong) NSMutableAttributedString *contentAtttrString;//cell的富文本内容 @end @interface MORtmGiftReturnForMultiple : NSObject @property (nonatomic, strong) MORtmUser *user;//用户信息 @property (nonatomic, copy) NSString *multiple;//返钻倍数 @property (nonatomic, assign) NSInteger diamond;//返还钻石 @property (nonatomic, assign) NSInteger giftCode;//礼物code @property (nonatomic, copy) NSString *roomId;//返钻获得的直播间ID @end @interface MORtmTranslate : NSObject @property (nonatomic, assign) NSInteger taskId;// 任务ID @property (nonatomic, copy) NSString *language;// 语言 @property (nonatomic, copy) NSString *result;// 翻译结果 @end @interface MORtmJosnEntity : NSObject //连麦 //连麦类型(1=视频连麦,2=语音连麦) //系统指令 (0:关闭直播间 1:指定用户禁言 2:解禁 3:踢出直播间用户) //RtmRoomTip 1: 关注 2: PK 3:禁言 //MOLikeComboTip 1首次点赞提示 2点赞连击(两秒钟) //RoomTipTwo 1: 用户升级 2: 直播间内开通VIP 3: 添加管理员 @property (nonatomic, assign) NSInteger type; //连麦 //状态 0:待审核 1:取消(观众) 2:同意(主播&管理员) 3:拒绝(主播&管理员) 4:挂断 5:上麦) 6, 主播邀请 7, 多人邀请- 用户同意 //Pk 邀请 //状态, 0:待处理 1:取消 2:同意 3:拒绝 //PK状态 //0:就绪 1:PK中 2:惩罚 3:结束 //频道通知 // 1: 关注 (1关注 0取关) 2: PK(0:失败 1:胜利 2:自己投降3:对方投降) 3:(0解除禁言 1禁言) @property (nonatomic, assign) NSInteger status; //上麦用户的声网ID @property (nonatomic, assign) NSInteger agoraId; @property (nonatomic, copy) NSString *userId; @property (nonatomic, copy) NSString *userName; @property (nonatomic, copy) NSString *avatar; @property (nonatomic, copy) NSString *pkSecret; @property (nonatomic, assign) NSInteger seatNum;//麦位 @property (nonatomic, assign) BOOL video1;//用户 - 麦位是否启用视频 @property (nonatomic, assign) BOOL video2;//主播 - 麦位是否启用视频 @property (nonatomic, assign) BOOL audio1;//用户 - 麦位是否启用音频 @property (nonatomic, assign) BOOL audio2;//主播 - 麦位是否启用音频 @property (nonatomic, assign) BOOL admin;//是否房管 @property (nonatomic, strong) MORtmDressing *dressing;//装饰类 @property (nonatomic, copy) NSString *invite;//多人连麦 - 邀请密匙 @property (nonatomic, assign) BOOL camera;//允许嘉宾打开摄像头 @property (nonatomic, strong) NSArray *linkMics;//麦位信息变化, 返回变化的麦位信息 @property (nonatomic, strong) NSDictionary *multipleChange; @property (nonatomic, strong) MOSettingInfo *changeSettingInfo; @property (nonatomic, assign) NSInteger vipType;//当前连麦人的vip等级 (单人连麦) @property (nonatomic, strong) NSArray *translateArr;//翻译的结果数组 //礼物 @property (nonatomic, assign) NSInteger code; @property (nonatomic, copy) NSString *name; @property (nonatomic, assign) NSInteger count; @property (nonatomic, strong) NSArray *multipleUserList; @property (nonatomic, assign) NSInteger rebateMultiple;//返钻倍数 @property (nonatomic, assign) NSInteger rebateDiamond;//返钻数量 @property (nonatomic, assign) NSInteger hitDiamond;//返钻暴击 钻石数 @property (nonatomic, assign) BOOL antiDrillCritGift;//返钻暴击 @property (nonatomic, assign) NSInteger priceDiamond;//钻石价格 //特效类型(0=无动效,1=自定义动效,2=第三方绑定动效) @property (nonatomic, assign) NSInteger effectType; //点赞连击数 @property (nonatomic, assign) NSInteger likeCombo; //发言 //内容 @property (nonatomic, copy) NSString *content; //目标用户ID 扩展字段 - @用户 @property (nonatomic, copy) NSString *targetUserId; //系统指令type为0时, 不为空 @property (nonatomic, copy) NSString *roomId; //礼物返钻 @property (nonatomic, strong) MORtmGiftRebate *giftSuperLucky; //活动中间对象 @property (nonatomic, strong) MORtmGiftRebate *activitySuperLucky2; //SL 中奖主播 @property (nonatomic, strong) MORtmGiftRebate *activitySl2Anchor; //内容 type=12时, 不为空, 钻石大赢家 @property (nonatomic, strong) MORtmGiftRebate *actBigWinner; //提示内容 @property (nonatomic, copy) NSString *tipContent; //奢华礼物信息 @property (nonatomic, strong) MORtmGiftRebate *luxury; /** 被@用户的UserId 使用英文逗号分隔 */ @property (nonatomic, copy) NSString *atList; /** 被@用户的昵称 使用英文逗号分隔 */ @property (nonatomic, copy) NSString *atNameList; @property (nonatomic, strong) MORedEnvelopeObject *redEnvelope; @property (nonatomic, strong) MORedEnvelopeObject *redEnvelopeFinished; //PK状态信息 @property (nonatomic, assign)double selfScore;//我方分数 @property (nonatomic, assign)double oppScore;//我方分数 @property (nonatomic, assign)NSInteger quitInfo;//中途结束信息 1:对方退出 2:对方投降 3:我方退出 4:我方投降, 0:单纯状态信息更新 //禁言 @property (nonatomic, assign) BOOL silence; @property (nonatomic, assign) BOOL manager; //是否是弹幕消息 @property (nonatomic, assign) BOOL danmu; /** 红包发送者的名字 */ @property (nonatomic, copy) NSString *redSendName; //红包ID @property (nonatomic, copy) NSString *redEId;//红包ID //系统更新消息 /** 时间版本号 */ @property (nonatomic, assign) double t; /** 主播金豆数 */ @property (nonatomic, assign) double g; /** 观众数量 */ @property (nonatomic, assign) double v; /** 管理员数量 */ @property (nonatomic, assign) double m; /** 直播间左上角卡片底图 */ @property (nonatomic, copy) NSString *c; /** 管理员数量 */ @property (nonatomic, strong) NSArray *l; /** 热度 */ @property (nonatomic, assign) double h; @property (nonatomic, assign) double suspendExpire;//主播挂起的截止时间 @property (nonatomic, assign) double planConvertTime;//房间转换时间 @property (nonatomic, assign) double diamond;//转换房间后 需要付款的金额 /** 红包雨ID */ @property (nonatomic, copy) NSString *redRainPeriodId; @property (nonatomic, strong) MORtmUser *roomUser;// 15=VIP 首次进入房间 房间用户,type=15,24时 ,必填 @property (nonatomic, copy) NSString *floatingBg;// 飘屏背景,type=15时 ,必填 @property (nonatomic, strong) MORtmRoomResolution *resolution;//16= 主播刷新房间分辨率(点对点) @property (nonatomic, strong) MORtmFlexActivityPiggy *activityPiggy;//20, 存钱罐数据 @property (nonatomic, strong) MORtmUserDialog *rtmUserDialog;//22 通用活动弹窗 @property (nonatomic, copy) NSString *nickName;//23 //新人进房提醒 @property (nonatomic, assign) NSInteger tipNormalNum; @property (nonatomic, strong) MORtmFansClub *fansClub;//粉丝团信息,type=24时,必填 @property (nonatomic, strong) MORtmOpenVipNotice *openVipNotice;//vip开通/续费 通知 type=25必填 @property (nonatomic, strong) MORtmUserLevelUpgrade *levelNotice;//RTM 用户等级升级通知. type=26时,必填 @property (nonatomic, strong) MORtmFastGive *fastGive;// RTM 快捷送礼 推送。type=27 @property (nonatomic, strong) MORtmFollowGive *followGive;// / RTM 快捷送礼 推送。type=28 @property (nonatomic, strong) NSArray *roomDesires;//RTM 房间心愿变更 推送. type=29 @property (nonatomic, strong) MORtmRoomDesireDone *desireDone;// RTM 房间心愿完成 推送, type=32 @property (nonatomic, strong) MORtmBlindboxDrawResult *blindboxDrawResult;//RTM 盲盒礼物中奖推送, type =33 @property (nonatomic, assign) BOOL hasInteractGift;//RTM 主播礼物菜单 推送 ,type=34 @property (nonatomic, strong) MORtmGiftReturnForMultiple *returnForMultiple;//返钻暴击礼物 推送 type = 35 @property (nonatomic, assign) BOOL allowLinkMic;//是否允许连麦。 RTM 房间连麦权限变更 推送,type=36 @property (nonatomic, strong, nullable) MORtmLivePKLinkInvite *pkLinkInvite;// type=37 ,pk/连线 邀请 RTM消息 @property (nonatomic, strong, nullable) MORtmPkV2Status *pkV2Status;//type=38,pk/连线 状态 信息 RTM @property (nonatomic, strong, nullable) MORtmPkV2StatusExpand *pkV2StatusExpand; // type=39,pk/连线 状态 信息-扩展信息 RTM @property (nonatomic, strong, nullable) MORtmToast *rtmToast; //type=40,直播间toast rtm @end @interface MORtmEntity : NSObject @property (nonatomic, assign) NSInteger type; @property (nonatomic, strong) MORtmUser *user; @property (nonatomic, strong) NSString *roomId; @property (nonatomic, strong) id data; /** 拼装的文本内容显示需要的高度 */ @property (nonatomic, assign) CGFloat cellHeight; /** 内容需要的宽度 */ @property (nonatomic, assign) CGFloat contentWidth; @property (nonatomic, strong) NSString *bizId;//临时生成的唯一ID @property (nonatomic, copy) NSString *blindBoxPropNotice;//盲盒礼物开出装扮的消息 //根据用户偏好缓存, 创建一个MORtmUser + (MORtmUser *)prepareBaseUser; //收到消息时, 将data解析成为真正的对象类 + (MORtmEntity *)prepareRealObjectWith:(MORtmEntity *)entity; //创建一条文本消息 + (MORtmEntity *)prepareRtmTextMessageWithType:(MORtmContentType )type AndText:(NSString *)text And:(BOOL)danMu AndRoomId:(NSString *)roomId; //创建一条艾特的文本 + (MORtmEntity *)prepareRtmTextMessageWithType:(MORtmContentType )type AndText:(NSString *)text And:(BOOL)danMu AndRoomId:(NSString *)roomId AndAtDict:(NSDictionary *)dict; //创建一条上麦申请消息 + (MORtmEntity *)prepareRtmApplyLianMaiMessageWithType:(MORtmContentType )type AndLinkMicType:(NSInteger)linkMicType AndRoomId:(NSString *)roomId; //创建一条 主播 审核 连麦信息 + (MORtmEntity *)prepareRtmManageLianMaiMessageWithType:(MORtmContentType )type AndLinkMicType:(NSInteger)linkMicType AndStatus:(NSInteger)status AndAgoraId:(NSInteger)agoraId AndRoomId:(NSString *)roomId; + (MORtmEntity *)prepareRtmManageAgreeLianMaiMessageAndLinkMicType:(NSInteger)linkMicType AndStatus:(NSInteger)status AndAgoraId:(NSInteger)agoraId AndUserId:(NSString *)userId AndUserName:(NSString *)userName AndAvatar:(NSString *)avatar AndRoomId:(NSString *)roomId AndVipType:(NSInteger)vipType; //创建一条 多人连麦的Rtm + (MORtmEntity *)prepareRtmManageAgreeLianMaiMessageAndLinkMicType:(NSInteger)linkMicType AndStatus:(NSInteger)status AndRoomId:(NSString *)roomId AndMOLinkMic:(MOLinkMic *)linkMic AndSeatNum:(NSInteger)seatNum; //创建一条上麦激活信息 - 广播通知所有人 + (MORtmEntity *)prepareRtmActiveLianMaiMessageWithType:(MORtmContentType)type AndLinkMicType:(NSInteger)linkMicType AndRoomId:(NSString *)roomId; //创建一条Pk 点对点消息 + (MORtmEntity *)prepareRtmPeerPkMessageWithStatus:(NSInteger)status PkSecretStr:(NSString *)pkSecretStr AndRoomId:(NSString *)roomId; //创建一条Pk 投降或者退出Rtm + (MORtmEntity *)prepareRtmPeerPkQuitMessageWith:(BOOL)isSurrender AndRoomId:(NSString *)roomId; //根据消息类型枚举 创建一条对应Rtm消息 + (MORtmEntity *)prepareRtmMessageWithType:(MORtmContentType )type AndRoomId:(NSString *)roomId; //准备一条 进入房间 Rtm + (MORtmEntity *)prepareRtmMessageWithEnterWith:(MOLiveDetail *)liveDetail; //准备一条 礼物 Rtm + (MORtmEntity *)prepareRtmGiftMessageWithCode:(NSInteger)code NameStr:(NSString *)nameStr Count:(NSInteger)count AndRoomId:(NSString *)roomId; + (MORtmEntity *)prepareRtmGiftMessageWith:(MOGiftInfo *)giftInfo AndRoomId:(NSString *)roomId; //准备一条 礼物数量 Rtm + (MORtmEntity *)prepareRtmGiftEndNumMessageWith:(MOGiftInfo *)giftInfo AndRoomId:(NSString *)roomId; /// 准备一条PK 房间状态信息 /// - Parameters: /// - pkModel: PK状态对象 /// - status: PK状态 0:就绪 1:PK中 2:惩罚 3:结束 /// - quitStatus: 中途结束信息 1:对方退出 2:对方投降 3:我方退出 4:我方投降, 0:单纯状态信息更新 + (MORtmEntity *)prepareRtmAboutPkStatusWith:(MOLiveList *)pkModel AndStatus:(NSInteger)status AndQuitStatus:(NSInteger)quitStatus AndRoomId:(NSString *)roomId; + (MORtmEntity *)preparePkRtmWith:(MOLinePKViewModel *)pkViewModel AndStatus:(NSInteger)status AndQuitStatus:(NSInteger)quitStatus AndRoomId:(NSString *)roomId; /// 准备一条房间踢人信息 /// - Parameter userId: 被踢的用户Id + (MORtmEntity *)prepareRtmAboutKickSomeOneWith:(NSString *)userId AndRoomId:(NSString *)roomId; /// 准备一条禁言消息 /// - Parameters: /// - userId: 被禁言 /// - isSilence: 是否被禁言 + (MORtmEntity *)prepareRtmAboutSilenceSomeOneWith:(NSString *)userId AndRoomId:(NSString *)roomId And:(BOOL)isSilence; /// 准备一条管理员信息 /// - Parameters: /// - userId: 用户ID /// - roomId: 房间ID + (MORtmEntity *)prepareRtmAboutManageSomeOneWith:(NSString *)userId AndRoomId:(NSString *)roomId And:(BOOL)isManager; /// 准备一条提示信息 /// - Parameters: /// - roomId: 房间ID /// - type: // 1: 关注 2: PK 3:禁言 /// - status: // 1: 关注 (1关注 0取关) 2: PK(0:失败 1: 胜利 2: 自己投降3:对方投降) 3:(0解除禁言 1禁言) 4:(0: 主播离开 1: 主播回来) /// - content: //提示内容, 有些类型需要 (非必传) + (MORtmEntity *)prePareRtmAboutRoomTipWithRoomId:(NSString *)roomId AndType:(NSInteger)type AndStatus:(NSInteger)status AndTipContent:(NSString *)content AndUserName:(NSString *)userName; // 准备一条 房间挂起的Rtm + (MORtmEntity *)prePareRtmAboutRoomTipWithRoomId:(NSString *)roomId AndType:(NSInteger)type AndStatus:(NSInteger)status AndTipContent:(NSString *)content AndUserName:(NSString *)userName AndSuspend:(double)suspend; /// 准备一条提示信息 (点赞连击) /// - Parameters: /// - roomId: 房间ID /// - type: // 1: 关注 2: PK 3:禁言4:首次点赞提示 5点赞连击(两秒钟) /// - likeNum: 点赞连击数 + (MORtmEntity *)prePareRtmAboutLikeComboWithRoomId:(NSString *)roomId AndType:(NSInteger)type AndLikeNum:(NSInteger)likeNum; /// 准备一条心愿单更新RTM /// - Parameters: /// - roomId: 房间ID /// - wishList: 接口数组 + (MORtmEntity *)prePareRtmAboutWishListWithRoomId:(NSString *)roomId AndWishList:(NSArray *)wishList; /// 准备一条语言翻译的Rtm /// - Parameters: /// - roomId: 房间ID /// - wishList: 接口数组 + (MORtmEntity *)prePareRtmAboutTranslateArrWithRoomId:(NSString *)roomId AndTranslateArr:(NSArray *)translateArr; /// 创建一条红包领取记录 /// - Parameters: /// - sendUserName: 发送红包者的nickName /// - redEId: 红包ID + (MORtmEntity *)prepareRtmAboutGetRedTipWithSendUserName:(NSString *)sendUserName RedId:(NSString *)redEId; /// 准备一条房间转换Rtm + (MORtmEntity *)prepareRtmAboutChangeRoomTypeWithRoomId:(NSString *)roomId AndType:(NSInteger)type AndPlanConvertTime:(double)planConvertTime AndDiamond:(double)diamond; /// 打招呼需求本地构造一条被房主艾特的消息 + (MORtmEntity *)prepareLocalChatMessage:(MOUserBase *)userModel content:(NSString *)content; /// 准备一条通用提示消息RoomTipTwo + (MORtmEntity *)prepareRoomTipTwoMessage:(NSInteger)type AndUserName:(NSString *)userName AndRoomId:(NSString *)roomId AndTipNormalNum:(NSInteger)tipNormalNum; #pragma mark - ChangeObject + (MOUserProfile *)toCreateUserProfileWith:(MORtmUser *)user; + (MODressing *)toCreateUserProfileDressingWith:(MORtmUser *)user; + (MOLinkMic *)toCreateLinkMicObjectWith:(MORTMLinkMic *)inObject; + (MOLinkMic *)toCreateLinkMicObjectWithEntity:(MORtmEntity *)entity; @end NS_ASSUME_NONNULL_END