예제 #1
0
        /// <summary>
        /// 撤回消息
        /// </summary>
        /// <param name="message">NIMIMMessage 对象</param>
        /// <param name="notify">自定义通知</param>
        /// <param name="cb"></param>
        public static void RecallMessage(NIMIMMessage message, string notify, RecallMessageDelegate cb)
        {
            var json = message.Serialize();
            var ptr  = NimUtility.DelegateConverter.ConvertToIntPtr(cb);

            TalkNativeMethods.nim_talk_recall_msg(json, notify, null, RecallMessageCb, ptr);
        }
예제 #2
0
        /// <summary>
        /// 撤回消息
        /// </summary>
        /// <param name="msgId">消息 id</param>
        /// <param name="notify">自定义通知</param>
        /// <param name="cb"></param>
        public static void RecallMessage(string msgId, string notify, RecallMessageDelegate cb)
        {
            var ptr = NimUtility.DelegateConverter.ConvertToIntPtr(cb);
            Dictionary <string, object> paramDic = new Dictionary <string, object>();

            paramDic[NIMIMMessage.ClientMessageId] = msgId;
            var json = NimUtility.Json.JsonParser.Serialize(paramDic);

            TalkNativeMethods.nim_talk_recall_msg(json, notify, null, RecallMessageCb, ptr);
        }