using Misc;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Reflection;
using System.Text;

namespace FLY.Thick.BlowingScan.Common
{
    /// <summary>
    /// 
    /// </summary>
    public class BlowingProfileParam : INotifyPropertyChanged,Misc.ICopiable,ICloneable
    {

        #region 正常运行参数
        /// <summary>
        /// 产品名称
        /// </summary>
        public string PName { get; set; }= "pname";
        /// <summary>
        /// 订单号
        /// </summary>
        public string OrderNo { get; set; } = "00000001";
        /// <summary>
        /// 卷号
        /// </summary>
        public string Number { get; set; } = "1";
        /// <summary>
        /// 目标值
        /// </summary>
        public double Target { get; set; } = 100;

        /// <summary>
        /// 公差%
        /// </summary>
        public double TolerancePercent { get; set; } = 0.03;

        /// <summary>
        /// 斜率补偿
        /// </summary>
        public double K { get; set; } = 1;


        #endregion

        /// <summary>
        /// 
        /// </summary>
        public event PropertyChangedEventHandler PropertyChanged;

        /// <summary>
        /// 
        /// </summary>
        /// <returns></returns>
        public object Clone()
        {
            BlowingProfileParam p = new BlowingProfileParam();
            p.Copy(this);
            return p;
        }

        /// <summary>
        /// 
        /// </summary>
        /// <param name="src"></param>
        public void Copy(object src)
        {
            Misc.PropertiesManager.CopyTo(src, this);
        }
    }

}