public static IntervalMessage <decimal> ToDecimal(this IIntervalMessage <float> message) { return(new IntervalMessage <decimal>( message.Timestamp, (decimal)message.High, (decimal)message.Low, (decimal)message.Open, (decimal)message.Close, message.TotalVolume, message.PeriodVolume, message.NumberOfTrades, message.RequestId)); }
public static IntervalMessage <float> ToFloat(this IIntervalMessage <double> message) { return(new IntervalMessage <float>( message.Timestamp, (float)message.High, (float)message.Low, (float)message.Open, (float)message.Close, message.TotalVolume, message.PeriodVolume, message.NumberOfTrades, message.RequestId)); }