using ServiceCenter.SqlSugars;
using WCS.Core;
using WCS.Entity.Protocol;
using WCS.Entity.Protocol.BCR;
using WCS.Entity.Protocol.DataStructure;
using WCS.Entity.Protocol.Protocol.DataStructure;
using WCS.Entity.Protocol.RGV;
using WCS.Entity.Protocol.Robot;
using WCS.Entity.Protocol.SRM;
using WCS.Entity.Protocol.Station;
using WCS.Entity.Protocol.Truss;
using WCS.WorkEngineering.Systems;

namespace WCS.WorkEngineering
{
    public class ProtocolProxy : ProtocolProxyBase
    {
        public static DeviceDataPack DataPack { get; set; } = new DeviceDataPack();

        public ProtocolProxy(Device dev, ProtocolInfo info, Type protocolType, World world) : base(dev, info, protocolType, world)
        {
        }

        protected override void DataChanged()
        {
        }

        public void DictionaryToEntity(Type type, Dictionary<string, PlcItem> plcItems, DeviceData data)
        {
        }

        public string GetString(string value)
        {
            return value.Replace("INSERT INTO ", "")
                .Replace(",N'", ",'")
                .Replace("\0", "")
                .Replace("wcs_", "")
                .Replace("(N'", "('") + "\r";
        }
    }
}
