old_flsystem/类库/Chat.Framework/WXSdk/Events/WXReiceveFriendMsg.cs

69 lines
1.8 KiB
C#

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Chat.Framework.WXSdk.Implement;
namespace Chat.Framework.WXSdk.Events
{
/// <summary>
/// 私聊消息事件
/// </summary>
public class WXReiceveFriendMsg : WXEvent
{
public override string ToString()
{
return $"微信({Client.User.Nick}【{Client.User.Uin}】)->私消息->{Friend.GetName()}({Friend.UserName})说:{Message}";
}
public WXReiceveFriendMsg(WXClientImpl_IPAD client, Friend friend, string message) : base(client)
{
IsToString = true;
this.Friend = friend;
this.Message = message;
}
public WXReiceveFriendMsg(WXClientImpl_HOOK client, Friend friend, string message) : base(client)
{
IsToString = true;
this.Friend = friend;
this.Message = message;
}
public WXReiceveFriendMsg(WXClientImpl_QYHOOK client, Friend friend, string message) : base(client)
{
IsToString = true;
this.Friend = friend;
this.Message = message;
}
/// <summary>
/// 发送者信息
/// </summary>
public Friend Friend { get; private set; }
private string _Message;
/// <summary>
/// 消息
/// </summary>
public string Message
{
get
{
return _Message;
}
private set
{
//_Message = Util.RemoveEmoji(value);
_Message = value;
}
}
/// <summary>
/// 是否为机器人自己的消息true是自己的消息
/// </summary>
public bool IsRobot { get; internal set; }
}
}