public static bool TryConvert(OpenQuant.API.Trade trade, ref StructRcvReport DepthMarketData) { if (tradeField == null) { tradeField = typeof(OpenQuant.API.Trade).GetField("trade", BindingFlags.NonPublic | BindingFlags.Instance); } TongShiTrade t = tradeField.GetValue(trade) as TongShiTrade; if (null != t) { DepthMarketData = t.DepthMarketData; return true; } return false; }
public static bool TryConvert(OpenQuant.API.Trade trade, ref CZQThostFtdcDepthMarketDataField DepthMarketData) { if (tradeField == null) { tradeField = typeof(OpenQuant.API.Trade).GetField("trade", BindingFlags.NonPublic | BindingFlags.Instance); } CTPZQTrade t = tradeField.GetValue(trade) as CTPZQTrade; if (null != t) { DepthMarketData = t.DepthMarketData; return(true); } return(false); }