/// <summary> /// Deserialization constructor. /// </summary> public ProviderTradeChartSeries(SerializationInfo info, StreamingContext context) : base(info, context) { _showOrderArrow = info.GetBoolean("showOrderArrow"); _showOrderSpot = info.GetBoolean("showOrderSpot"); _showClosedOrdersTracing = info.GetBoolean("showClosedOrdersTracing"); _showPendingOrdersTracing = info.GetBoolean("showPendingOrdersTracing"); _buyDashedPen = (Pen)info.GetValue("buyDashedPen", typeof(Pen)); _sellDashedPen = (Pen)info.GetValue("sellDashedPen", typeof(Pen)); _showCurrentAskLine = info.GetBoolean("showCurrentAskLine"); _showCurrentBidLine = info.GetBoolean("showCurrentBidLine"); _priceLevelPen = (Pen)info.GetValue("priceLevelPen", typeof(Pen)); _lineDrawingSource = (DataBar.DataValueEnum)info.GetInt32("lineDrawingSource"); }
public double[] GetValuesAsDouble(DataBar.DataValueEnum valueEnum, int startingIndex, int indexCount) { double[] result; lock (this) { int count = indexCount; if (count == 0) { count = _dataBars.Count - startingIndex; GeneralHelper.Verify(count >= 0, "Invalid starting index."); } result = new double[Math.Min(count, _dataBars.Count)]; for (int i = startingIndex; i < startingIndex + count && i < _dataBars.Count; i++) { result[i - startingIndex] = (double)_dataBars[i].GetValue(valueEnum); } } return(result); }
public double[] GetValuesAsDouble(DataBar.DataValueEnum valueEnum) { return(GetValuesAsDouble(valueEnum, 0, int.MaxValue)); }
public decimal[] GetValues(DataBar.DataValueEnum valueEnum) { return(GetValues(valueEnum, 0, int.MaxValue)); }