MsgExtend.cs
612 字节
using OnlineStore.Common;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace DeviceLibrary
{
public static class MsgExtend
{
public static void add(this List<Msg> msgs, string msgtxt, MsgLevel msgLevel)
{
msgs.Add(new Msg { msgtxt = msgtxt, msgLevel = msgLevel, datetime = DateTime.Now });
//LogUtil.OutputDebugString(msgtxt);
}
public static void loginfo(this IRobot t, string msgtxt)
{
LogUtil.info(t.DeviceName + " " + msgtxt);
}
}
}