using System; using CY.Infrastructure.Domain; using CY.Infrastructure.Common; namespace CY.Model { /// ///Inquiry_ReduceWorkCountSet /// [Serializable] public partial class Inquiry_ReduceWorkCountSet : IAggregateRoot { public Inquiry_ReduceWorkCountSet() { } #region Model private int? _keyid; private Guid _firmid; private Guid _customerid; private int? _count; /// /// KeyId /// public int? KeyId { get{ return _keyid; } set{ _keyid = value; } } /// /// FirmId /// public Guid FirmId { get{ return _firmid; } set{ _firmid = value; } } /// /// CustomerId /// public Guid CustomerId { get{ return _customerid; } set{ _customerid = value; } } /// /// Count /// public int? Count { get{ return _count; } set{ _count = value; } } #endregion Model #region Visiter /// /// 属性访问器 /// /// 属性名 /// 索引 /// 是否将指定属性设置为传入值 /// 需要赋予的值 /// 与名称对应的属性值 public object Visiter(string name, int? index = -1, bool isChange = false, object value = null) { object theValue = null; if ("KeyId".Equals(name,StringComparison.CurrentCultureIgnoreCase) || index == 1) { this.KeyId = isChange ? MyConvert.ConvertToInt(value) : KeyId; theValue = this.KeyId; } else if ("FirmId".Equals(name,StringComparison.CurrentCultureIgnoreCase) || index == 2) { this.FirmId = isChange ? MyConvert.ConvertToGuid(value) : FirmId; theValue = this.FirmId; } else if ("CustomerId".Equals(name,StringComparison.CurrentCultureIgnoreCase) || index == 3) { this.CustomerId = isChange ? MyConvert.ConvertToGuid(value) : CustomerId; theValue = this.CustomerId; } else if ("Count".Equals(name,StringComparison.CurrentCultureIgnoreCase) || index == 4) { this.Count = isChange ? MyConvert.ConvertToInt(value) : Count; theValue = this.Count; } return theValue; } #endregion Visiter } }