예제 #1
0
        public Indicator.GomCD GomCD(GomCDCalculationModeType calcMode, GomCDChartType chart, string fileFormat, Gom.FileModeType fileModeType, GomFilterModeType filterMode, int filterSize, bool reinitSession)
        {
            Indicator.GomCD indy = _indicator.GomCD(calcMode, chart, fileFormat, filterMode, filterSize, reinitSession);
            indy.FileMode = fileModeType;

            return(indy);
        }
예제 #2
0
파일: GomCD.cs 프로젝트: yuxi214/ninja-code
        /// <summary>
        /// Gom Cumulative Delta
        /// </summary>
        /// <returns></returns>
        public Indicator.GomCD GomCD(Data.IDataSeries input, GomCDChartType chart, bool reinitSession)
        {
            if (InInitialize && input == null)
            {
                throw new ArgumentException("You only can access an indicator with the default input/bar series from within the 'Initialize()' method");
            }

            return(_indicator.GomCD(input, chart, reinitSession));
        }
예제 #3
0
파일: GomCD.cs 프로젝트: yuxi214/ninja-code
        /// <summary>
        /// Gom Cumulative Delta
        /// </summary>
        /// <returns></returns>
        public GomCD GomCD(Data.IDataSeries input, GomCDChartType chart, bool reinitSession)
        {
            if (cacheGomCD != null)
            {
                for (int idx = 0; idx < cacheGomCD.Length; idx++)
                {
                    if (cacheGomCD[idx].Chart == chart && cacheGomCD[idx].reinitSession == reinitSession && cacheGomCD[idx].EqualsInput(input))
                    {
                        return(cacheGomCD[idx]);
                    }
                }
            }

            lock (checkGomCD)
            {
                checkGomCD.Chart         = chart;
                chart                    = checkGomCD.Chart;
                checkGomCD.reinitSession = reinitSession;
                reinitSession            = checkGomCD.reinitSession;

                if (cacheGomCD != null)
                {
                    for (int idx = 0; idx < cacheGomCD.Length; idx++)
                    {
                        if (cacheGomCD[idx].Chart == chart && cacheGomCD[idx].reinitSession == reinitSession && cacheGomCD[idx].EqualsInput(input))
                        {
                            return(cacheGomCD[idx]);
                        }
                    }
                }

                GomCD indicator = new GomCD();
                indicator.BarsRequired        = BarsRequired;
                indicator.CalculateOnBarClose = CalculateOnBarClose;
#if NT7
                indicator.ForceMaximumBarsLookBack256 = ForceMaximumBarsLookBack256;
                indicator.MaximumBarsLookBack         = MaximumBarsLookBack;
#endif
                indicator.Input         = input;
                indicator.Chart         = chart;
                indicator.reinitSession = reinitSession;
                Indicators.Add(indicator);
                indicator.SetUp();

                GomCD[] tmp = new GomCD[cacheGomCD == null ? 1 : cacheGomCD.Length + 1];
                if (cacheGomCD != null)
                {
                    cacheGomCD.CopyTo(tmp, 0);
                }
                tmp[tmp.Length - 1] = indicator;
                cacheGomCD          = tmp;
                return(indicator);
            }
        }
예제 #4
0
        public GomCD GomCD(GomCDCalculationModeType calcMode, GomCDChartType chart, string fileFormat, GomFilterModeType filterMode, int filterSize, bool reinitSession)
        {
            GomCD indy = GomCD(Input, calcMode, chart, reinitSession);

            indy.FileFormat = fileFormat;
            indy.FilterMode = filterMode;
            indy.FilterSize = filterSize;


            return(indy);
        }
예제 #5
0
파일: GomCD.cs 프로젝트: yuxi214/ninja-code
 public Indicator.GomCD GomCD(GomCDChartType chart, bool reinitSession)
 {
     return(_indicator.GomCD(Input, chart, reinitSession));
 }
예제 #6
0
파일: GomCD.cs 프로젝트: yuxi214/ninja-code
 /// <summary>
 /// Gom Cumulative Delta
 /// </summary>
 /// <returns></returns>
 public Indicator.GomCD GomCD(Data.IDataSeries input, GomCDChartType chart, bool reinitSession)
 {
     return(_indicator.GomCD(input, chart, reinitSession));
 }
예제 #7
0
파일: GomCD.cs 프로젝트: yuxi214/ninja-code
 /// <summary>
 /// Gom Cumulative Delta
 /// </summary>
 /// <returns></returns>
 public GomCD GomCD(GomCDChartType chart, bool reinitSession)
 {
     return(GomCD(Input, chart, reinitSession));
 }
예제 #8
0
 public Indicator.GomCD GomCD(GomCDCalculationModeType calcMode, GomCDChartType chart, bool reinitSession)
 {
     return(_indicator.GomCD(Input, calcMode, chart, reinitSession));
 }
예제 #9
0
        public GomCD GomCD(GomCDChartType chart, bool reinitSession)
        {
            GomCD indy = GomCD(GomCDCalculationModeType.BidAsk, chart, reinitSession);

            return(indy);
        }
예제 #10
0
 public Indicator.GomCD GomCD(GomCDCalculationModeType calcMode, GomCDChartType chart, bool reinitSession)
 {
     return _indicator.GomCD(Input, calcMode, chart, reinitSession);
 }
예제 #11
0
        /// <summary>
        /// Gom Cumulative Delta
        /// </summary>
        /// <returns></returns>
        public Indicator.GomCD GomCD(Data.IDataSeries input, GomCDCalculationModeType calcMode, GomCDChartType chart, bool reinitSession)
        {
            if (InInitialize && input == null)
                throw new ArgumentException("You only can access an indicator with the default input/bar series from within the 'Initialize()' method");

            return _indicator.GomCD(input, calcMode, chart, reinitSession);
        }
예제 #12
0
 /// <summary>
 /// Gom Cumulative Delta
 /// </summary>
 /// <returns></returns>
 public Indicator.GomCD GomCD(Data.IDataSeries input, GomCDCalculationModeType calcMode, GomCDChartType chart, bool reinitSession)
 {
     return _indicator.GomCD(input, calcMode, chart, reinitSession);
 }
예제 #13
0
        /// <summary>
        /// Gom Cumulative Delta
        /// </summary>
        /// <returns></returns>
        public GomCD GomCD(Data.IDataSeries input, GomCDCalculationModeType calcMode, GomCDChartType chart, bool reinitSession)
        {
            if (cacheGomCD != null)
                for (int idx = 0; idx < cacheGomCD.Length; idx++)
                    if (cacheGomCD[idx].CalcMode == calcMode && cacheGomCD[idx].Chart == chart && cacheGomCD[idx].reinitSession == reinitSession && cacheGomCD[idx].EqualsInput(input))
                        return cacheGomCD[idx];

            lock (checkGomCD)
            {
                checkGomCD.CalcMode = calcMode;
                calcMode = checkGomCD.CalcMode;
                checkGomCD.Chart = chart;
                chart = checkGomCD.Chart;
                checkGomCD.reinitSession = reinitSession;
                reinitSession = checkGomCD.reinitSession;

                if (cacheGomCD != null)
                    for (int idx = 0; idx < cacheGomCD.Length; idx++)
                        if (cacheGomCD[idx].CalcMode == calcMode && cacheGomCD[idx].Chart == chart && cacheGomCD[idx].reinitSession == reinitSession && cacheGomCD[idx].EqualsInput(input))
                            return cacheGomCD[idx];

                GomCD indicator = new GomCD();
                indicator.BarsRequired = BarsRequired;
                indicator.CalculateOnBarClose = CalculateOnBarClose;
#if NT7
                indicator.ForceMaximumBarsLookBack256 = ForceMaximumBarsLookBack256;
                indicator.MaximumBarsLookBack = MaximumBarsLookBack;
#endif
                indicator.Input = input;
                indicator.CalcMode = calcMode;
                indicator.Chart = chart;
                indicator.reinitSession = reinitSession;
                Indicators.Add(indicator);
                indicator.SetUp();

                GomCD[] tmp = new GomCD[cacheGomCD == null ? 1 : cacheGomCD.Length + 1];
                if (cacheGomCD != null)
                    cacheGomCD.CopyTo(tmp, 0);
                tmp[tmp.Length - 1] = indicator;
                cacheGomCD = tmp;
                return indicator;
            }
        }
예제 #14
0
		public Indicator.GomCD GomCD(GomCDCalculationModeType calcMode, GomCDChartType chart, string fileFormat, Gom.FileModeType fileModeType,GomFilterModeType filterMode, int filterSize, bool reinitSession)
        {
            Indicator.GomCD indy = _indicator.GomCD(calcMode,chart,fileFormat,filterMode,filterSize,reinitSession);
			indy.FileMode=fileModeType;

            return indy;
        }
예제 #15
0
		public  GomCD GomCD(GomCDChartType chart, bool reinitSession)
        {
            GomCD indy = GomCD(GomCDCalculationModeType.BidAsk,chart,reinitSession);
			
            return indy;
        }
예제 #16
0
		public GomCD GomCD(GomCDCalculationModeType calcMode, GomCDChartType chart, string fileFormat, GomFilterModeType filterMode, int filterSize, bool reinitSession)
        {
            GomCD indy = GomCD(Input,calcMode,chart,reinitSession);
			indy.FileFormat=fileFormat;
            indy.FilterMode = filterMode;
            indy.FilterSize = filterSize;


            return indy;
        }