public override void OnInputItemAdded(object sender, DateTimeEventArgs EventArgs) { if (!this.Monitored) return; int index = this.fInput.GetIndex(EventArgs.DateTime); if (index == -1) return; for (int Index = index; Index <= Math.Min(this.fInput.Count - 1, index + 1); ++Index) this.Calculate(Index); }
private void HandleSeriesItemAdded(object sender, DateTimeEventArgs e) { bool flag = false; lock (this.dataLock) { this.contentUpdated = true; if (this.firstIndex == -1) this.firstIndex = 0; switch (this.updateStyle) { case ChartUpdateStyle.WholeRange: this.SetPadIntervals(0, this.mainSeries.Count - 1); flag = true; break; case ChartUpdateStyle.Trailing: if (this.lastIndex - this.firstIndex + 1 < this.minCountOfBars) this.SetPadIntervals(this.firstIndex, this.lastIndex + 1); else this.SetPadIntervals(this.firstIndex + 1, this.lastIndex + 1); flag = true; break; } } if (flag) this.Invalidate(); Application.DoEvents(); }
protected override void OnInputItemAdded2(object sender, DateTimeEventArgs EventArgs) { int index = this.fInput.GetIndex(EventArgs.DateTime); if (index != -1) this.fHL_array.Add(this.fInput.GetDateTime(index), this.fInput[index, BarData.High] - this.fInput[index, BarData.Low]); base.OnInputItemAdded2(sender, EventArgs); }
public override void OnInputItemAdded(object sender, DateTimeEventArgs EventArgs) { if (!this.Monitored) return; int index = this.fInput.GetIndex(EventArgs.DateTime); if (index == -1) return; if (this.fStyle == EIndicatorStyle.QuantStudio) { for (int Index = index; Index <= Math.Min(this.fInput.Count - 1, index + this.fLength); ++Index) this.Calculate(Index); } else { for (int Index = index; Index <= this.fInput.Count - 1; ++Index) this.Calculate(Index); } }
private void OnInputItemAdded(object sender, DateTimeEventArgs args) { double num = this.Calculate(this.series.GetIndex(args.DateTime)); if (double.IsNaN(num)) return; ((DoubleSeries)this.indicator).Add(args.DateTime, num); }
public override void OnInputItemAdded(object sender, DateTimeEventArgs EventArgs) { int index = this.fInput.GetIndex(EventArgs.DateTime); if (index == -1) return; for (int Index = index; Index <= this.fInput.Count - 1; ++Index) this.Calculate(Index); }
public override void OnInputItemAdded(object sender, DateTimeEventArgs EventArgs) { if (!this.Monitored) return; int index = this.fInput.GetIndex(EventArgs.DateTime); if (index == -1) return; if (index == this.fInput.Count - 1) { this.Calculate(index); } else { this.rDfv3IEXe(); this.Clear(); for (int Index = 0; Index <= this.fInput.Count - 1; ++Index) this.Calculate(Index); } }
private void oq2A1bOgQG(object obj0, DateTimeEventArgs obj1) { DateTime index = obj1.DateTime; switch (this.k5kAXvwmyK) { case TriggerType.Above: if (this.fISADbUH9Z[index] <= this.J3YAFHAWt0) break; this.rKEA9ZLnkT(); this.eiNALoFbZL = new Signal(Clock.Now, this.eiNALoFbZL.Sender, this.eiNALoFbZL.Type, this.eiNALoFbZL.Side, this.eiNALoFbZL.Qty, this.eiNALoFbZL.Price, this.eiNALoFbZL.Instrument, this.eiNALoFbZL.Text); this.nquAKcUOSY.BgvpSPpUAD(this.eiNALoFbZL); this.KWCAC961IE(TriggerStatus.Executed); break; case TriggerType.Below: if (this.fISADbUH9Z[index] >= this.J3YAFHAWt0) break; this.rKEA9ZLnkT(); this.eiNALoFbZL = new Signal(Clock.Now, this.eiNALoFbZL.Sender, this.eiNALoFbZL.Type, this.eiNALoFbZL.Side, this.eiNALoFbZL.Qty, this.eiNALoFbZL.Price, this.eiNALoFbZL.Instrument, this.eiNALoFbZL.Text); this.nquAKcUOSY.BgvpSPpUAD(this.eiNALoFbZL); this.KWCAC961IE(TriggerStatus.Executed); break; } }
public override void OnInputItemAdded(object sender, DateTimeEventArgs EventArgs) { int index = this.fInput.GetIndex(EventArgs.DateTime); if (index == -1) return; this.fHL_array.Add(this.fInput.GetDateTime(index), this.fInput[index, BarData.High] - this.fInput[index, BarData.Low]); if (!this.Monitored) return; for (int Index = index; Index <= this.fInput.Count - 1; ++Index) this.Calculate(Index); }
public virtual void OnInputItemAdded(object sender, DateTimeEventArgs e) { if (!this.fMonitored) return; int index = this.fInput.GetIndex(e.DateTime); if (index == -1) return; this.Calculate(index); }
protected virtual void OnInputItemAdded2(object sender, DateTimeEventArgs e) { if (this.inputCalculate) return; if (this.fCalculate) this.Calculate(); this.OnInputItemAdded(sender, e); }