/// <summary> /// Initializes a new instance of the <see cref="InlineResponse2003" /> class. /// </summary> /// <param name="total">total (required).</param> /// <param name="scale">scale (required).</param> /// <param name="distribution">distribution (required).</param> public InlineResponse2003(WalletswalletIdpaymentfeesAmount total = default(WalletswalletIdpaymentfeesAmount), ScaleEnum scale = default(ScaleEnum), Dictionary <string, int?> distribution = default(Dictionary <string, int?>)) { // to ensure "total" is required (not null) if (total == null) { throw new InvalidDataException("total is a required property for InlineResponse2003 and cannot be null"); } else { this.Total = total; } // to ensure "scale" is required (not null) if (scale == null) { throw new InvalidDataException("scale is a required property for InlineResponse2003 and cannot be null"); } else { this.Scale = scale; } // to ensure "distribution" is required (not null) if (distribution == null) { throw new InvalidDataException("distribution is a required property for InlineResponse2003 and cannot be null"); } else { this.Distribution = distribution; } }
internal Scale(ScaleEnum scale, int interval) { this.scaleType = scale; this.interval = interval; this.beginning = 0; if (scale == ScaleEnum.undefined) l.Error("масштаб Scale не определен"); }
internal Scale(ScaleEnum scale, int interval) { this.scaleType = scale; this.interval = interval; this.beginning = 0; if (scale == ScaleEnum.undefined) { l.Error("масштаб Scale не определен"); } }
internal Scale(ScaleEnum scale, int interval, int beginning) { this.scaleType = scale; this.interval = interval; this.beginning = beginning; if (scale == ScaleEnum.undefined) l.Error("масштаб Scale не определен"); name = SetName(); }
internal Scale(ScaleEnum scale, int interval, int beginning) { this.scaleType = scale; this.interval = interval; this.beginning = beginning; if (scale == ScaleEnum.undefined) { l.Error("масштаб Scale не определен"); } name = SetName(); }
public IScale GetScale(ScaleEnum scale, int interval, int beginning) { foreach (IScale s in scales) { if ((s.beginning == beginning) && (s.scaleType == scale) && (s.interval == interval)) { return(s); } } IScale newS = new Scale(scale, interval, beginning); scales.Add(newS); return(newS); }
/// <summary> /// Возвращает строковое значение указанного масштаба. /// </summary> /// <param name="scale">Масштаб.</param> /// <returns></returns> public static string GetString(this ScaleEnum scale) => _scaleStringsList[scale];
/// <summary> /// Возвращает численное значение указанного масштаба. /// </summary> /// <param name="scale">Масштаб.</param> /// <returns></returns> public static double GetValue(this ScaleEnum scale) => _scaleValuesList[scale];
public IBars GetBars(string marketName, string symbol, ScaleEnum scale, int interval) { return GetBars(GetSymbol(marketName, symbol), GetScale(scale, interval)); }
public IScale GetScale(ScaleEnum scale, int interval) { return GetScale(scale, interval, 0); }
public IScale GetScale(ScaleEnum scale, int interval, int beginning) { foreach (IScale s in scales) if ((s.beginning == beginning) && (s.scaleType == scale) && (s.interval == interval)) return s; IScale newS = new Scale(scale, interval, beginning); scales.Add(newS); return newS; }
public IScale GetScale(ScaleEnum scale, int interval) { return(GetScale(scale, interval, 0)); }
public IBars GetBars(string marketName, string symbol, ScaleEnum scale, int interval) { return(GetBars(GetSymbol(marketName, symbol), GetScale(scale, interval))); }