namespace Muchinfo.MTPClient.Data.Model.QuoteItem
{
///
/// QuoteItemBase2类
///
public class QuoteItemBase2 : QuoteItemBase
{
#region Fields
///
/// 买价
///
private decimal _buyPrice;
///
/// 买量
///
private int _buyVolume;
///
/// 现量
///
private int _currentVolume;
///
/// 排序
///
private int _order;
///
/// 报价货币
///
private string _quoteCurrency;
///
/// 卖价
///
private decimal _sellPrice;
///
/// 卖量
///
private int _sellVolume;
///
/// 总量
///
private int _totalVolume;
#endregion Fields
#region Properties
#region Public Properties
///
/// 买价
///
public decimal BuyPrice
{
get
{
return _buyPrice;
}
set
{
Set(() => BuyPrice, ref _buyPrice, value);
}
}
///
/// 买量
///
public int BuyVolume
{
get
{
return _buyVolume;
}
set
{
Set(() => BuyVolume, ref _buyVolume, value);
}
}
///
/// 现量
///
public int CurrentVolume
{
get
{
return _currentVolume;
}
set
{
Set(() => CurrentVolume, ref _currentVolume, value);
}
}
///
/// 排序
///
public int Order
{
get
{
return _order;
}
set
{
Set(() => Order, ref _order, value);
}
}
///
/// 报价货币
///
public string QuoteCurrency
{
get
{
return _quoteCurrency;
}
set
{
Set(() => QuoteCurrency, ref _quoteCurrency, value);
}
}
///
/// 卖价
///
public decimal SellPrice
{
get
{
return _sellPrice;
}
set
{
Set(() => SellPrice, ref _sellPrice, value);
}
}
///
/// 卖量
///
public int SellVolume
{
get
{
return _sellVolume;
}
set
{
Set(() => SellVolume, ref _sellVolume, value);
}
}
///
/// 总量
///
public int TotalVolume
{
get
{
return _totalVolume;
}
set
{
Set(() => TotalVolume, ref _totalVolume, value);
}
}
#endregion Public Properties
#endregion Properties
#region Methods
#region Public Methods
///
/// 更新对象属性值(只更新需要字段)
///
/// The item.
public override void UpdateFrom(QuoteItemBase item)
{
base.UpdateFrom(item);
var item2 = item as QuoteItemBase2;
if (item2 == null)
{
return;
}
this.BuyPrice = item2.BuyPrice;
this.BuyVolume = item2.BuyVolume;
this.CurrentVolume = item2.CurrentVolume;
this.SellPrice = item2.SellPrice;
this.SellVolume = item2.SellVolume;
this.TotalVolume = item2.TotalVolume;
}
#endregion Public Methods
#endregion Methods
}
}