using YLErp.DBModels; namespace YLErp.Abstract.DataProviders { /// /// 标的数据基础提供接口 /// public interface IUnderlyingProvider { /// /// 根据标的ID获取标的 /// underlying_manager GetUnderlying(int underlyingId); /// /// 根据标的代码获取标的 /// underlying_manager GetUnderlying(string underlyingCode); /// /// 根据标的代码获取标的 /// underlying_manager GetUnderlying(string underlyingCode, out double contractSize); } /// /// 标的数据及关联数据提供 /// public interface IUnderlyingDataProvider : IUnderlyingProvider { /// /// 获取品种信息 /// Variety GetVariety(int varietyId); /// /// 获取品种数据 /// /// 标的代码 Variety GetVariety(string underlyingCode); /// /// 获取品种信息 /// Variety GetVariety(string underlyingCode, out double contractSize); /// /// 根据标的代码获取份额和数量的乘积因子(最小为1) /// int GetCountRatio(string underlyingCode); /// /// 尝试获取标的过期日(股票:2099-01-01),如果标的信息不存在返回false /// bool TryGetMaturityDate(string underlyingCode, out DateTime date); /// /// 根据标的代码获取场内期权标的 /// ExchangeListOption GetExchange_List_Option(string ContractCode); /// /// 获取相关性 /// CorrelationTable GetCorrelation(int underlyingId1, int underlyingId2); /// /// 获取组合标的 /// SyntheticUnderlying GetSyntheticUnderlying(string underlyingCode); } }